tc_2018
7 years agoContributor
How to declare controls and objects globally?
Hi,
I am trying to find a way to declare controls and objects globally.
Currently, I have to repeat buttons, text boxes, and etc... in every script file as shown below:
def test1():
login_window = Sys.Process("my_app").VBObject("login") #repeat in every script file
user_name_box = login_window.VBObject("txtUserName") #repeat in every script file
user_name_box.SetText("test")
Can anyone show me a way to declare those lines below globally once so I can call user_name_box in any script files?
login_window = Sys.Process("my_app").VBObject("login") #repeat in every script file
user_name_box = login_window.VBObject("txtUserName") #repeat in every script file
Thanks.
See the second option I mentioned above.