资源名称:ERPSYS.zip [点击查看]
上传用户:zhpu1995
上传日期:2013-09-06
资源大小:61151k
文件大小:3k
源码类别:
企业管理
开发平台:
Visual Basic
- VERSION 5.00
- Begin VB.Form CBHS_FormulaGen
- BorderStyle = 3 'Fixed Dialog
- Caption = "自定义公式生成"
- ClientHeight = 3855
- ClientLeft = 2760
- ClientTop = 3750
- ClientWidth = 7335
- Icon = "成本核算_自定义公式生成.frx":0000
- LinkTopic = "Form1"
- MaxButton = 0 'False
- MinButton = 0 'False
- ScaleHeight = 3855
- ScaleWidth = 7335
- ShowInTaskbar = 0 'False
- Begin VB.TextBox txtFormula
- Height = 1095
- Left = 90
- MultiLine = -1 'True
- TabIndex = 4
- Top = 2610
- Width = 5865
- End
- Begin VB.TextBox txtDescribe
- Height = 2415
- Left = 3360
- MultiLine = -1 'True
- TabIndex = 3
- Top = 60
- Width = 3885
- 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 = 3240
- Width = 1125
- End
- Begin VB.CommandButton OKButton
- Caption = "确定(&O)"
- Height = 300
- Left = 6120
- TabIndex = 0
- Top = 2820
- Width = 1125
- End
- End
- Attribute VB_Name = "CBHS_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