ANW
14 years agoContributor
Calling WinFormsObjects question
I have yet another newbie question regarding WinFormsObjects.
When I tested Delphi applications, I never used the VCLObejct('') part of an object name, and wanted to do the same with WinFormsObjects, as the full path name quickly becomes very big and cumbersome.
Anyways, using the recorder to test some things in my new apps, I could see that the recorder sometimes discarded the WinFormsObject part, and sometimes not, and I can't really figure out why.
Here is an example of a method call that works:
Sys.Process('VictorTEST').CreateCustomer.tsCreatedCustomer.tabItem1.gbCompany.clientPicker1.WinFormsObject('comboBox1').ClickItem
Now i thought, I could just remove the WinFormsObject around comboBox1, but then I get a runtime error (ClickItem is then an unknown method). Why do I need it for the comboBox1 and not the other objects??
When I tested Delphi applications, I never used the VCLObejct('') part of an object name, and wanted to do the same with WinFormsObjects, as the full path name quickly becomes very big and cumbersome.
Anyways, using the recorder to test some things in my new apps, I could see that the recorder sometimes discarded the WinFormsObject part, and sometimes not, and I can't really figure out why.
Here is an example of a method call that works:
Sys.Process('VictorTEST').CreateCustomer.tsCreatedCustomer.tabItem1.gbCompany.clientPicker1.WinFormsObject('comboBox1').ClickItem
Now i thought, I could just remove the WinFormsObject around comboBox1, but then I get a runtime error (ClickItem is then an unknown method). Why do I need it for the comboBox1 and not the other objects??