I've found some weird behavior with this project but don't know why it happens.
If you compile to pcode instead of native code, errors that would normally show a popup (overflow, file not found, etc) just end up killing the program.
You can use these steps to reproduce
1. Add a button with the following code
dim d as double
d = 1 / 0
2. go to the Compile tab in the project properties and select Pcode
3. compile and run the exe (you must run the exe, the ide behaves correctly)
4. click the button and the exe crashes without showing the overflow error message
I'm still having trouble figuring out why compiling to pcode causes the program to close instead of showing error messages. Does anyone have any insight into this?
2. go to the Compile tab in the project properties and select Pcode
3. compile and run the exe (you must run the exe, the ide behaves correctly)
4. click the button and the exe crashes without showing the overflow error message
Does anyone know why this happens?
I just compiled a test project to p-code and it does show a message box with
Code:
---------------------------
Project1
---------------------------
Run-time error '11':
Division by zero
---------------------------
OK
---------------------------
I've tried compiling on a few different computers but I keep getting the same behavior.
This seems to be a bug in VB6 concerning a custom user-control containing another custom user-control when events are frozen by the container.
To work around it just remove/comment out UserControl_Resize event implementation in GossClient user-control (not Gossamer).
@dilettante: No idea why this is failing w/ p-code compile but GossClient's fixed size makes no difference altogether and might consider scraping it's UserControl_Resize at some point if new version gets released.
We spent a lot of time trying to find what was causing this. How did you pinpoint the resize event?
I removed the Gossamer user-control from the failing form and placed another empty user-control instead and noticed that upon fatal "Division by zero" MsgBox this user-control became checkered as being marked inactive so there must be some repainting interaction going on between container form and its contained user-controls on this fatal MsgBox but Paint in not implemented anywhere, only Resize so. . .
It took me 5 minutes and 20 years of previous VB6 experience :-))
I removed the Gossamer user-control from the failing form and placed another empty user-control instead and noticed that upon fatal "Division by zero" MsgBox this user-control became checkered as being marked inactive so there must be some repainting interaction going on between container form and its contained user-controls on this fatal MsgBox but Paint in not implemented anywhere, only Resize so. . .
It took me 5 minutes and 20 years of previous VB6 experience :-))
cheers,
</wqw>
again, can't thank you enough for looking at this. was driving us crazy for several days, works perfectly now.