以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  怎么返回选定区域可见列  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=147455)

--  作者:紫色幽魂
--  发布时间:2020/3/17 12:47:00
--  怎么返回选定区域可见列
请教怎么返回选定区域可见列,这样设置返回的是全部列,也包含了隐藏列
With CurrentTable
    If .TopPosition > -1 Then \'如果选定区域包括数据行
        For i1 As Integer = .TopPosition To .BottomPosition
            For i2 As Integer = .LeftCol To .RightCol
                Output.Show( .Rows(i1)("_Identify")  & " : " & .Cols(i2).name)
            Next
        Next
    End If
End With

[此贴子已经被作者于2020/3/17 12:47:20编辑过]

--  作者:有点蓝
--  发布时间:2020/3/17 13:51:00
--  
            For i2 As Integer = .LeftCol To .RightCol
if .Cols(i2).visible then
                Output.Show( .Rows(i1)("_Identify")  & " : " & .Cols(i2).name)
end if
            Next