以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.net/bbs/index.asp)
--  专家坐堂  (http://foxtable.net/bbs/list.asp?boardid=2)
----  带数组的内部函数如何设置,并如何调用?  (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=124061)

--  作者:ZJZK2018
--  发布时间:2018/8/29 20:15:00
--  带数组的内部函数如何设置,并如何调用?
内部函数:JMLSZ

\'\'\'======批量列设置保存=====

Dim e As Object = Args(0)

Dim nms() As String = Args(1)

Dim pth As String = ProjectPath & "Syscm\\用户设置\\" \'设置保存路径

If FileSys.DirectoryExists(pth)  = False Then

    FileSys.CreateDirectory(pth)

Else

    \'Dim nms() As String = {"Table1","Table2","Table3","Table4"}

    Dim cvs As String = ""

    For Each nm As String In nms

        cvs &=  e.Form.Controls(nm).Table.GetColVisibleWidth & chr(11)

    Next

    Dim form As String = e.Form.name

    Dim dd As String = pth & form & ".txt"

    FileSys.WriteAllText(dd, cvs.trim(chr(11)), False, Encoding.Default)

End If


调用函数:

Functions.Execute("JMLSZ",e,***)


Dim nms() As String = {"Table1","Table2","Table3","Table4"} 因为各个界面的table不一样,我想到每个界面上进行调整?


--  作者:有点甜
--  发布时间:2018/8/29 20:58:00
--  

参考

 

Dim nms() As String = {"Table1","Table2","Table3","Table4"}

Functions.Execute("JMLSZ",e, nms)