Embarrassed - Form rename

enonod

Well-Known Member
Licensed User
Longtime User
I have been away a long time and restarting B4PPC with 6.80. No excuse!
I just started a new project and created the form with a button.
Worked.
I named the form other than Form1 and I got an error stating that 'show' was not a known control or object.
The offending code - Main.show instead of Form1.show.
The form with its name was presumably saved when I responded that I wished to keep the changes. The offending line was changed automatically as expected.
Hence the title.
 

klaus

Expert
Licensed User
Longtime User
What name did you give the Form ?
If you gave "Main" then you have the problem that "Main" is also the name of the Main module.
That means that you should write:
Main.Main.Show
the 1st Main is the module name and the 2nd Main is the form name.

Best regards.
 

enonod

Well-Known Member
Licensed User
Longtime User
Thank you Klaus, I didn't expect that, perhaps now I can continue. Such is coincidence!
 
Top