Okay, first future reference. In VB's IDE, goto the menu>Tools>Options and put a check in the box next to where it says Require Variable Declaration.
Okay, now for your problem. You are checking Form1's windowstate and setting form2's. Is form2 even loaded? If not then the problem may be that you are trying to access the properties of a form that is not loaded.
But this does not make sense so I have to ask. Are you sure you are using VB6 and not .NET or VBA (Excel, access, word)?
SO, if you are sure that you are using VB6 then goto vb's menu>Progect>References and the first four items should be these in this order...
Visual Basic For Applications
Visual Basic runtime objects and procedures
Visual Basic objects and procedures
Don't know what to tell you abu, your original problem "form2.show" being highlighted was more than likely because form2 did not exist. Look in the object window (Project window) on the right and see what you have named your forms. Do you have a form or forms showing like this... formTest(Form1)... if so, the name within the parenthesis () is the file name and the name before the parens is the name you should use in code.
my form name is mreport. no problem with from & form. i write it just like an example. I have many button to show many form. all are ok. but only this form made problem. when I press a button to show then show this msg. when I press ok. then the form show. but no problem happend.
Hi. I have a form with list box : lst_product, datagridview : grd_order and button: btn_addline. lst_product has a list of product ids selected from database (MS Acess 2013) , grd_order is by default empty except for 2 headers and btn_addline adds rows to grd_order.
OK, so HostGator for some reason no longer allows gcc/g++ access unless you have a Designated Server account, which is a lot of money to spend just to compile my "Hello World" program. Thus I figured I'd compile at home, then upload. Program is your regular old bare-bones Hello World ...
Hi, as I was told that my code doesn’t scale well at all, I thought perhaps I’d try to get a better understanding of interfaces/abstract classes and classes and the relationship between them.
I don’t want at this stage work on a big separate project as I've already got plenty ...