以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  [求助] 修改列名称  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=178620)

--  作者:建筑人生
--  发布时间:2022/7/12 15:09:00
--  [求助] 修改列名称

Dim wtb As WinForm.Table = e.Form.Controls("Tab_中转报表")
Dim tb As Table = wtb.Table
Dim x As String
For Each c As Col In tb.Cols
    Select Case c.Name
        Case "序号1", "序号2"
            c.Caption = "序号"
        Case "科目名称1", "科目名称2"
            c.Caption = "科目名称"
        Case "借方1", "借方2"
            c.Caption = "借方"
        Case "贷方1", "贷方2"
            c.Caption = "贷方"
        Case "差额1", "差额2"
            c.Caption = "差额"
    End Select
Next

 

以上代码运行后列名称还是显示原来序号1、序号2等,没有修改

[此贴子已经被作者于2022/7/12 15:09:06编辑过]

--  作者:有点蓝
--  发布时间:2022/7/12 15:23:00
--  
要这样:http://www.foxtable.com/webhelp/topics/1275.htm