Link to home
Start Free TrialLog in
Avatar of farenet
farenet

asked on

Problems with user defined types (VB3)

I have a big problem with the VB3 editor, concerning type declarations!!! If I start a program while debugging code, the following mysterious thing happens:
After editing a line with an user-defined-type and continuing the program, VB3 does not accept the user-defined type (udt) anymore (error message:"Identifier is not an object or user-defined-type"). When the program is stopped and you want to start the program again, the same error message comes up.
Finally, if you redefines the variable, a simply space in the line of ("Global gtVar as tType"), and starting the program again, everything works without problems until you edit a line with this udt.

Some additional informations:
This bug has not appeared from the beginning in the program. Not every global udt has this bug. The size of the udt is not responsible for the bug. Small types and big types have the same problem.

To restart VB can´t be the solution!!!
Avatar of Msoft
Msoft

Hi,
I think that all UDT must be global and declared In Module.
Maybe you declared variable and UTD at same name or same name to VB Global Constants.



Do you have decleared it public?

/johan

I have seen this behavior with VB3 on several occaisions.  I write it off to the general flakiness of the product, save my files, exit VB, and reload VB.  In fact, this is my response to any number of flaky behaviors VB3 has.
Avatar of farenet

ASKER

Edited text of question
ASKER CERTIFIED SOLUTION
Avatar of mheacock
mheacock

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial