以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.net/bbs/index.asp)
--  专家坐堂  (http://foxtable.net/bbs/list.asp?boardid=2)
----  [求助]控件集合  (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=184805)

--  作者:bzqlyj
--  发布时间:2023/1/4 12:46:00
--  [求助]控件集合
有多个e.Form.Controls("PictureViewer1") 、e.Form.Controls("PictureViewer2") 、e.Form.Controls("PictureViewer3") 
如何全用下面的功能
Dim pv1 As WinForm.PictureViewer = e.Form.Controls("PictureViewer1") 
pv1.DeleteCommand.Visible = False 
pv1.ClearCommand.Visible = False 
pv1.SaveAsCommand.Visible = False 
pv1.OpenCommand.Enabled =False  

--  作者:有点蓝
--  发布时间:2023/1/4 13:32:00
--  
for i as integer = 1 to 3
Dim pv1 As WinForm.PictureViewer = e.Form.Controls("PictureViewer" & i) 
pv1.DeleteCommand.Visible = False 
pv1.ClearCommand.Visible = False 
pv1.SaveAsCommand.Visible = False 
pv1.OpenCommand.Enabled =False  
next