新增文章
文章标题
分类
C#
云星空
K3 BOS
K3 功能
用友
Oracle
python
SQL
MySql
PHP
HTML
script
windows
Access
影视后期
财务
服务
生活
内容
Option Explicit '强制声明变量 Dim sValue As String Private WithEvents m_BillInterface As BillEvent '定义 BillEvent 接口. 必须具有的声明, 以此来获得事件 Attribute m_BillInterface.VB_VarHelpID = -1 Public Sub Show(ByVal oBillInterface As Object) 'BillEvent 接口实现 注意: 此方法必须存在, 请勿修改 Set m_BillInterface = oBillInterface End Sub Private Sub Class_Terminate() '释放接口对象 '注意: 此方法必须存在, 请勿修改 Set m_BillInterface = Nothing End Sub Private Sub m_BillInterface_AfterLoadBill() '单据加载后事件 '---------------------------------------------------------------------------------- Dim sKey As String: sKey = m_BillInterface.TableInfo("Map")("FTime") Dim sValue As String: sValue = m_BillInterface.Data("page1")(sKey)("FFLD") Dim dtValue As Date If Len(sValue) > 0 Then '用 Len 来比较,速度比 = Null 快 dtValue = CDate(sValue) '文本转日期 End If '---------------------------------------------------------------------------------- sKey = m_BillInterface.TableInfo("Map")("FQty") sValue = m_BillInterface.Data("page2")(1)(sKey)("FFLD") '取得字段值 Dim dbQty As Double If Len(sValue) > 0 And IsNumeric(sValue) Then dbQty = CDbl(sValue) '文本转数字 End If MsgBox "审核日期为:" & dtValue & " 第一行实收数量为:" & dbQty '--------------------------------------------------------------------------------- m_BillInterface.BillEntrys(1).MaxRows = 2000 '单据最大行数扩充至2000 End Sub Private Sub m_BillInterface_AfterNewBill() '单据新增时触发 m_BillInterface.BillEntrys(1).MaxRows = 2000 '单据最大行数扩充至2000 End Sub
返回
保存