资源名称:ERPSYS.zip [点击查看]
上传用户:zhpu1995
上传日期:2013-09-06
资源大小:61151k
文件大小:3k
源码类别:
企业管理
开发平台:
Visual Basic
- VERSION 5.00
- Begin VB.Form AutoTran_FormulaGen
- BorderStyle = 3 'Fixed Dialog
- Caption = "自定义公式生成"
- ClientHeight = 3810
- ClientLeft = 2760
- ClientTop = 3750
- ClientWidth = 7335
- Icon = "自动转帐凭证_自定义公式生成.frx":0000
- LinkTopic = "Form1"
- MaxButton = 0 'False
- MinButton = 0 'False
- ScaleHeight = 3810
- ScaleWidth = 7335
- ShowInTaskbar = 0 'False
- Begin VB.TextBox txtFormula
- Height = 1155
- Left = 90
- MultiLine = -1 'True
- TabIndex = 4
- Top = 2550
- Width = 5865
- End
- Begin VB.TextBox txtDescribe
- Height = 2415
- Left = 3270
- MultiLine = -1 'True
- TabIndex = 3
- Top = 60
- Width = 3975
- End
- Begin VB.ListBox lstFunction
- Height = 2400
- ItemData = "自动转帐凭证_自定义公式生成.frx":000C
- Left = 90
- List = "自动转帐凭证_自定义公式生成.frx":0013
- TabIndex = 2
- Top = 90
- Width = 3135
- End
- Begin VB.CommandButton CancelButton
- Caption = "取消(&C)"
- Height = 300
- Left = 6120
- TabIndex = 1
- Top = 3210
- Width = 1125
- End
- Begin VB.CommandButton OKButton
- Caption = "确定(&O)"
- Height = 300
- Left = 6120
- TabIndex = 0
- Top = 2850
- Width = 1125
- End
- End
- Attribute VB_Name = "AutoTran_FormulaGen"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- Option Explicit
- Dim str_Describe() As String
- Private Sub CancelButton_Click()
- Unload Me
- End Sub
- Private Sub Form_Load()
- txtFormula.Text = Glo_FormulaString
- FillListBox
- End Sub
- Private Sub lstFunction_Click()
- txtDescribe.Text = str_Describe(lstFunction.ListIndex)
- End Sub
- Private Sub lstFunction_DblClick()
- txtFormula.SelText = lstFunction.Text
- End Sub
- Private Sub OKButton_Click()
- Glo_FormulaString = txtFormula.Text
- Unload Me
- End Sub
- Function FillListBox() As String '填充列表框并定位
- '函数参数:列表框,列表框分组编码,定位内容,填充类型(0-无空记录 1-有空记录(1个空格) )
- Dim Lbknrrec As adodb.Recordset
- Dim int_Count As Integer
- '填充列表框内容
- Set Lbknrrec = Cw_DataEnvi.DataConnect.Execute("select * from cwzz_UserDefineFn")
- lstFunction.Clear
- ReDim str_Describe(Lbknrrec.RecordCount - 1) As String
- Do While Not Lbknrrec.EOF
- lstFunction.AddItem Trim(Lbknrrec("fnalias") & "")
- str_Describe(int_Count) = Trim(Lbknrrec("fncomment") & "")
- int_Count = int_Count + 1
- Lbknrrec.MoveNext
- Loop
- '定位列表框内容
- lstFunction.ListIndex = 0
- End Function