📄 frmfetch.frm
字号:
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 120
TabIndex = 14
Top = 810
Width = 840
End
Begin VB.Label Label2
AutoSize = -1 'True
Caption = "医 师:"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 105
TabIndex = 13
Top = 1335
Width = 840
End
Begin VB.Label Label1
AutoSize = -1 'True
Caption = "就诊科别:"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 2505
TabIndex = 12
Top = 1305
Width = 1050
End
Begin VB.Label Label6
AutoSize = -1 'True
Caption = "处方:"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 30
TabIndex = 10
Top = 4170
Width = 525
End
Begin VB.Label lblFairTotal
AutoSize = -1 'True
Caption = "lblFair"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H8000000D&
Height = 210
Left = 675
TabIndex = 9
Tag = "Dyn"
Top = 4185
Width = 735
End
Begin VB.Label Label10
AutoSize = -1 'True
Caption = "取药:"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Left = 30
TabIndex = 8
Top = 4440
Width = 525
End
Begin VB.Label lblFair
AutoSize = -1 'True
Caption = "lblFair"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H8000000D&
Height = 210
Left = 660
TabIndex = 7
Tag = "Dyn"
Top = 4440
Width = 735
End
Begin VB.Line Line2
BorderColor = &H8000000C&
X1 = 0
X2 = 9480
Y1 = 4755
Y2 = 4755
End
Begin VB.Line Line3
BorderColor = &H80000009&
X1 = 0
X2 = 9450
Y1 = 4740
Y2 = 4740
End
End
Attribute VB_Name = "frmFetchBus"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Public SickObj As clsSickOP
Public mID As String
Private Fetchsobj As clsFetchs
Private CurFetchObj As clsFetch
Public WithEvents QueryObj As frmFetchQuery
Attribute QueryObj.VB_VarHelpID = -1
Private Sub printBus()
Dim i As Integer
spd.Row = spd.MaxRows
spd.Col = 1
If spd.Text = "" Then
If lblPkCount.Visible Then
spd.Text = "每副合计"
Else
spd.Text = "合 计"
End If
spd.Col = 6
spd.Text = lblFair
Else
spd.Col = 1
spd.MaxRows = spd.MaxRows + 1
spd.Row = spd.MaxRows
If lblPkCount.Visible Then
spd.Text = "每副合计"
Else
spd.Text = "合 计"
End If
spd.Col = 6
spd.Text = lblFair
End If
spd1.Col = -1
spd1.Row = -1
spd1.Text = ""
spd1.MaxRows = spd.MaxRows
For i = 1 To spd.MaxRows
spd.Row = i
spd1.Row = i
spd.Col = 1
spd1.Col = 1
spd1.Text = spd.Text
spd.Col = 2
spd1.Col = 2
spd1.Text = spd.Text
spd.Col = 3
spd1.Col = 3
spd1.Text = spd.Text
spd.Col = 6
spd1.Col = 4
spd1.Text = spd.Text
spd.Col = 5
spd1.Col = 5
spd1.Text = spd.Text
spd.Col = 7
spd1.Col = 6
spd1.Text = spd.Text
spd.Col = 8
spd1.Col = 7
If i < spd.MaxRows Then
If spd.Text = "1" Then
spd1.Text = "公费"
Else
spd1.Text = "自费"
End If
End If
Next i
If lblPkCount.Visible Then
spd1.MaxRows = spd1.MaxRows + 1
spd1.Row = spd1.MaxRows
spd1.Col = 1
spd1.Text = "共 " & CurFetchObj.PKCount & " 副总计"
spd1.Col = 6
spd1.Text = lblFairTotal
End If
spd1.PrintHeader = " /fz""12"" /fb1" & gtydSysConfig.HospName & " 药品明细单/n/n" _
& "/fz""10"" /fb0 病人ID:" & txtID & Space(4) & "姓名:" & txtName & Space(6) & "日期:" & gfnGetTime(gstrCHINA_DATE)
spd1.PrintBorder = False
spd1.PrintColHeaders = True
spd1.PrintRowHeaders = False
spd1.PrintShadows = False
spd1.PrintGrid = False
spd1.PrintMarginLeft = 0
spd1.PrintUseDataMax = False
spd1.Action = SS_ACTION_PRINT
spd1.Redraw = True
End Sub
Private Sub InitForm()
' Call hisFormToCenter(Me, frmMain)
Set Me.lct.CN = gDbObj.CN
lct.Visible = False
init
Set usp.DBInter = gDbObj
Set usp.CurSpread = spd
usp.Load
End Sub
Private Sub init()
hisFormClear Me
cmdPrevRecipeNum.Enabled = False
cmdNextRecipeNum.Enabled = False
spd.MaxRows = 0
If Not (SickObj Is Nothing) Then
Set SickObj = Nothing
End If
If Not (Fetchsobj Is Nothing) Then
Set Fetchsobj = Nothing
End If
If gtydSysConfig.DeFaultPatientID Then
txtID = gfnGetTime("yymmdd")
End If
lblPkCount = "草药副数:"
End Sub
Private Sub cmdNextRecipeNum_Click()
lblRecipeNum = lblRecipeNum + 1
If lblRecipeNum = lblRecipeTotal Then
cmdNextRecipeNum.Enabled = False
End If
cmdPrevRecipeNum.Enabled = True
Set CurFetchObj = Fetchsobj.Item(Val(lblRecipeNum))
FillDataByFetch
End Sub
Private Sub cmdPrevRecipeNum_Click()
lblRecipeNum = lblRecipeNum - 1
If lblRecipeNum = "1" Then
cmdPrevRecipeNum.Enabled = False
End If
cmdNextRecipeNum.Enabled = True
Set CurFetchObj = Fetchsobj.Item(Val(lblRecipeNum))
FillDataByFetch
End Sub
Private Sub FillData() '门诊取药填界面
Me.lblRecipeTotal = Fetchsobj.Count
lblRecipeNum = "1"
If lblRecipeNum = lblRecipeTotal Then
cmdNextRecipeNum.Enabled = False
Else
cmdNextRecipeNum.Enabled = True
End If
cmdPrevRecipeNum.Enabled = False
Set CurFetchObj = Fetchsobj.Item(Val(lblRecipeNum))
FillDataByFetch
End Sub
Private Sub FillDataByFetch() '门诊取药填界面处方
Dim i As Integer
Dim RTotal As Currency
txtDoctor = CurFetchObj.DcName
txtDepart = CurFetchObj.DepName
spd.MaxRows = 0
spd.MaxRows = CurFetchObj.Count
lblDate = CurFetchObj.RecentFetchDate
If CurFetchObj.Ack Then
mcr.KeyEnabled(BK_ADD) = False
Else
mcr.KeyEnabled(BK_ADD) = True
End If
lblPkCount = "共 " & CurFetchObj.PKCount & " 副"
mskPkCount = Format(CurFetchObj.PKCount, "000")
If CurFetchObj.PKCount > 1 Then
fraPK.Visible = True
Else
fraPK.Visible = False
End If
For i = 1 To spd.MaxRows
spd.Row = CurFetchObj.Item(i).ItemNum
spd.Col = 1
spd.Text = CurFetchObj.Item(i).itemname
spd.Col = 2
spd.Text = CurFetchObj.Item(i).Model & " * " & CurFetchObj.Item(i).Factor
spd.Col = 3
spd.Text = CurFetchObj.Item(i).Unit
spd.Col = 4
spd.Text = CurFetchObj.Item(i).ActAmount / CurFetchObj.Item(i).Factor / CurFetchObj.PKCount
spd.Col = 5
spd.Text = CurFetchObj.Item(i).FetchAmount / CurFetchObj.Item(i).Factor / CurFetchObj.PKCount
spd.Col = 6
spd.Text = CurFetchObj.Item(i).CPrice * CurFetchObj.Item(i).Factor
spd.Col = 7
spd.Text = CurFetchObj.Item(i).FetchFair / CurFetchObj.PKCount
RTotal = RTotal + Val(spd.Text)
spd.Col = 8
spd.Value = IIf(CurFetchObj.Item(i).Pub, 1, 0)
spd.Col = 9
spd.Value = IIf(CurFetchObj.Item(i).Export, 1, 0)
Next i
Sum
End Sub
Private Sub Form_KeyPress(KeyAscii As Integer)
If KeyAscii = vbKeyReturn And Me.ActiveControl.Name <> "spdFigure" Then
hisToActiveCtl(Me, True).SetFocus
KeyAscii = 0
End If
End Sub
Private Sub Form_Load()
InitForm
fraPK.Visible = False
End Sub
Private Sub Form_Unload(Cancel As Integer)
Set frmFetchBus = Nothing
frmFecthList.closeflag = True
Unload frmFecthList
End Sub
Private Sub Sum()
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -