📄
字号:
Top = 1710
Width = 11295
_ExtentX = 19923
_ExtentY = 10980
_ConvInfo = 1
Appearance = 1
BorderStyle = 1
Enabled = -1 'True
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
MousePointer = 0
BackColor = 16777215
ForeColor = -2147483640
BackColorFixed = 12632256
ForeColorFixed = -2147483630
BackColorSel = -2147483635
ForeColorSel = -2147483634
BackColorBkg = -2147483636
BackColorAlternate= 16777215
GridColor = -2147483633
GridColorFixed = -2147483632
TreeColor = -2147483632
FloodColor = 192
SheetBorder = -2147483642
FocusRect = 1
HighLight = 1
AllowSelection = -1 'True
AllowBigSelection= -1 'True
AllowUserResizing= 0
SelectionMode = 0
GridLines = 1
GridLinesFixed = 2
GridLineWidth = 1
Rows = 50
Cols = 10
FixedRows = 1
FixedCols = 1
RowHeightMin = 0
RowHeightMax = 0
ColWidthMin = 0
ColWidthMax = 0
ExtendLastCol = 0 'False
FormatString = ""
ScrollTrack = 0 'False
ScrollBars = 3
ScrollTips = 0 'False
MergeCells = 0
MergeCompare = 0
AutoResize = -1 'True
AutoSizeMode = 0
AutoSearch = 0
MultiTotals = -1 'True
SubtotalPosition= 1
OutlineBar = 0
OutlineCol = 0
Ellipsis = 0
ExplorerBar = 0
PicturesOver = 0 'False
FillStyle = 0
RightToLeft = 0 'False
PictureType = 0
TabBehavior = 0
OwnerDraw = 0
Editable = 0 'False
ShowComboButton = -1 'True
WordWrap = 0 'False
TextStyle = 0
TextStyleFixed = 0
OleDragMode = 0
OleDropMode = 0
DataMode = 0
VirtualData = -1 'True
End
Begin MSComctlLib.Toolbar Tlb_Action
Align = 1 'Align Top
Height = 570
Left = 0
TabIndex = 2
Top = 0
Width = 11400
_ExtentX = 20108
_ExtentY = 1005
ButtonWidth = 820
ButtonHeight = 953
AllowCustomize = 0 'False
Wrappable = 0 'False
Appearance = 1
Style = 1
ImageList = "ImageList1"
_Version = 393216
BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628}
NumButtons = 8
BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "设置"
Key = "ymsz"
Object.ToolTipText = "打印页面设置"
ImageKey = "sz"
EndProperty
BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "打印"
Key = "dy"
Object.ToolTipText = "打印当前单据或Ctrl+P"
ImageKey = "dy"
EndProperty
BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "预览"
Key = "yl"
ImageKey = "yl"
EndProperty
BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628}
Style = 3
EndProperty
BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "删行"
Key = "sh"
Object.ToolTipText = "删除当前记录行或Delete"
ImageKey = "sh"
EndProperty
BeginProperty Button6 {66833FEA-8583-11D1-B16A-00C0F0283628}
Style = 3
EndProperty
BeginProperty Button7 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "帮助"
Key = "bz"
ImageKey = "bz"
EndProperty
BeginProperty Button8 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "退出"
Key = "fh"
ImageKey = "tc"
EndProperty
EndProperty
BorderStyle = 1
Begin MSComctlLib.Toolbar GsToolbar
Height = 540
Left = 9720
TabIndex = 6
Top = 0
Width = 1695
_ExtentX = 2990
_ExtentY = 953
ButtonWidth = 1455
ButtonHeight = 953
AllowCustomize = 0 'False
Appearance = 1
Style = 1
ImageList = "ImageList1"
_Version = 393216
BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628}
NumButtons = 2
BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "保存格式"
Key = "bcgs"
ImageKey = "bcgs"
EndProperty
BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "默认列宽"
Key = "hfmrgs"
ImageKey = "mrlk"
EndProperty
EndProperty
End
End
Begin VB.Label Lab_OperStatus
BackColor = &H000080FF&
Caption = "1"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 345
Left = 10980
TabIndex = 5
Top = 1230
Visible = 0 'False
Width = 345
End
End
Attribute VB_Name = "YS_FrmDeptBudget"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'**************************************************************************************************
'* 模 块 名 称 :部门预算表
'* 功 能 描 述 :对所进行预算的会计科目的预算金额录入
'* 程序员姓名 :魏永生
'* 最后修改人 :魏永生
'* 最后修改时间:2001/07/26
'* 备 注:程序中所有依实际情况自定义部分均用[>> <<]括起
'*
'* 1.每次调入外部功能窗体,均要加锁ChangeLock=True,窗体关闭后解锁ChangeLock=false
'*
'* 2.网格列存储内容注解
'*
'* 0-行有效标识 1-记录编辑唯一标识 2-科目编码
'*
'* 3.Lab_OperStatus 用此标签来标识单据录入状态(默认值为1) 1-浏览 2-修改
'**************************************************************************************************
'以下为固定使用变量(网格)
Dim Cxnrrec As New ADODB.Recordset '显示查询内容动态集
Dim Dyymctbl As New DY_Dyymsz '打印页面窗体变量
Dim GridCode As String '显示网格网格代码
Dim GridInf() As Variant '整个网格设置信息
Dim ReportTitle As String '报表主标题
Dim Tsxx As String '系统提示信息
Dim Pmbcsjhs As Long '屏幕网格保持数据行数(大于等于1)
Dim Fzxwghs As Integer '辅助项网格行数(包括合计行)
Dim Sfxshjwg As Boolean '是否显示合计网格
Dim Qslz As Long '网格隐藏(非操作显示)列数
Dim Sjhgd As Double '网格数据行高度
Dim GridBoolean() As Boolean '网格列信息(布尔型)
Dim GridStr() As String '网格列信息(字符型)
Dim GridInt() As Integer '网格列信息(整型)
Dim Sfblbzkd As Boolean '是否保留帮助宽度(字段提供帮助时,是否为按钮保留空间)
Dim Dqlrwgh As Long '当前录入数据网格行
Dim Dqlrwgl As Long '当前录入数据网格列
Dim Dqlkwgh As Long '刚刚离开网格行(不一定为录入行)
Dim Dqlkwgl As Long '刚刚离开网格列
Dim Dqtoprow As Long '当前录入状态时最上端可视行
Dim Dqleftcol As Long '当前录入状态时最左端可视列
Dim Zdlrqnr As String '字段录入修改前内容(用来判断内容是否修改)
Dim Wbkbhlock As Boolean '文本框改变值锁
Dim changelock As Boolean '网格行列改变控制锁(用来区别用户改变.程序改变)
Dim Gdtlock As Boolean '滚动条滚动控制(用来区别用户改变.程序改变)
Dim Yxxpdlock As Boolean '字段有效性判断锁(内容不修改不需进行字段有效性判断)
Dim Hyxxpdlock As Boolean '行有效性判断锁(字段内容不修改不需进行行有效性判断)
Dim Valilock As Boolean '文本框失去焦点是否进行有效性控制(TRUE 为锁定*限用网格录入)
Dim Shsfts As Boolean '删除记录行是否提示
Dim Szzls As Integer '网格信息数组最大下标值(网格列数-1)
Private Sub Form_KeyPress(KeyAscii As Integer) '控制焦点转移和限制录入字符"'"
Select Case KeyAscii
Case 39 '屏蔽字符"'"
KeyAscii = 0
End Select
End Sub
Private Sub Form_Load() '窗 体 装 入
Dim RecTemp As New ADODB.Recordset '临时使用动态集
'隐藏选择对话框
lbl_AccountYear.Caption = Str(Int_OriYear)
Lbl_Dept = Trim(Str_DeptName)
YS_FrmDeptBudgetC.Hide
'初始化各种锁值
changelock = False '网格行列改变控制锁
Gdtlock = False '滚动条滚动控制
Yxxpdlock = True '字段有效性判断锁
Hyxxpdlock = True '行有效性判断锁
Wbkbhlock = False '文本框内容改变锁
'报表主标题及报表编码
ReportTitle = "部门预算表"
XtReportCode = "cwfx_Budget"
Load Dyymctbl
'调 入 网 格
GridCode = "cwfx_Budget" '网格属性编码
Call BzWgcsh(WglrGrid, GridCode, GridInf(), GridBoolean(), GridInt(), GridStr())
Qslz = GridInf(1)
Sjhgd = GridInf(2)
Pmbcsjhs = GridInf(3)
Fzxwghs = GridInf(4)
Sfblbzkd = GridInf(5)
Shsfts = GridInf(6)
Sfxshjwg = GridInf(7)
Szzls = WglrGrid.Cols - 1
'生成查询结果
Call Sub_Query
'设置状态为修改状态
Lab_OperStatus = "2"
End Sub
Private Sub Form_Unload(Cancel As Integer) '窗体卸载
'卸载打印页面窗体
Unload Dyymctbl
Unload YS_FrmDeptBudgetC
End Sub
Private Sub Sub_Query() '生成查询结果
Dim SqlStr As String '查询字符串
Dim RecTemp As New ADODB.Recordset '临时使用动态集
Dim Jsqte As Long '临时计数器
Dim Cur_SumBudget As Currency
SqlStr = "SELECT Cwfx_DeptBudgetMaster.*,CName FROM Cwfx_DeptBudgetMaster,Cwzz_AccCode "
SqlStr = SqlStr + " where Cwfx_DeptBudgetMaster.CCode=Cwzz_AccCode.CCode And Year=" & Str(Int_OriYear) & " and DeptCode='" & Str_DeptCode & "'"
SqlStr = SqlStr + " order by Cwfx_DeptBudgetMaster.Ccode "
Set RecTemp = Cw_DataEnvi.DataConnect.Execute(SqlStr)
With RecTemp
WglrGrid.Clear 1
WglrGrid.Rows = .RecordCount + WglrGrid.FixedRows
Jsqte = WglrGrid.FixedRows
Do While Not .EOF
If Jsqte >= WglrGrid.Rows Then
WglrGrid.AddItem ""
End If
WglrGrid.TextMatrix(Jsqte, 0) = "*" '有效记录标识
WglrGrid.TextMatrix(Jsqte, 1) = Trim(.Fields("I_id")) '记录唯一标识
WglrGrid.TextMatrix(Jsqte, 2) = Trim(.Fields("CCode"))
WglrGrid.TextMatrix(Jsqte, Sydz("001", GridStr(), Szzls)) = Trim(.Fields("Cname"))
WglrGrid.TextMatrix(Jsqte, Sydz("002", GridStr(), Szzls)) = IIf(.Fields("Budget_1") = 0, "", .Fields("budget_1"))
WglrGrid.TextMatrix(Jsqte, Sydz("003", GridStr(), Szzls)) = IIf(.Fields("Add_1") = 0, "", .Fields("Add_1"))
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -