开发者

Call a form sub from another form

开发者 https://www.devze.com 2023-01-20 22:33 出处:网络
I have a form Friend Class frmOrganigramma Inherits System.Windows.Forms.Form with a sub Sub OutList() How can I lau开发者_运维技巧nch this sub from another form?By passing an instance of the f

I have a form

Friend Class frmOrganigramma
    Inherits System.Windows.Forms.Form

with a sub

Sub OutList()

How can I lau开发者_运维技巧nch this sub from another form?


By passing an instance of the first form to the constructor of the second form (also make sure the method is public) or by externalizing this function in some other utility class which you would use from both forms.

0

精彩评论

暂无评论...
验证码 换一张
取 消