By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,986 Members | 1,487 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,986 IT Pros & Developers. It's quick & easy.

Hitch in VB6

P: n/a
I discovered an amazing hitch in VB6 SP6.

I run a Sub Main that shows a splash screen, initializes a number of items,
takes down the splash screen, and shows the main form.

While trying to track another problem that I couldn't run in the IDE because
this problem (an ADODB OLEDB connection to an SQL Database that runs fine in
Windows 2K, and blows up on the recordset open in XP) has to be run on
another machine without VS6 installed, I inserted a whole string of msgbox's
to track down the offending statement.

The last msgbox is after the final form show, and before the Exit Sub in my
Sub Main. Guess what happened to me next?

When run under these circumstances in the IDE, the main form load event
fires as expected, AND THE FORM ACTIVATE EVENT DOESN'T!

SP7 anyone?
Oct 28 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a

"David C. Barber" <da***@NOSPAMdbarber.comwrote in message
news:qI******************************@comcast.com. ..
>I discovered an amazing hitch in VB6 SP6.

I run a Sub Main that shows a splash screen, initializes a number of
items,
takes down the splash screen, and shows the main form.

While trying to track another problem that I couldn't run in the IDE
because
this problem (an ADODB OLEDB connection to an SQL Database that runs fine
in
Windows 2K, and blows up on the recordset open in XP) has to be run on
another machine without VS6 installed, I inserted a whole string of
msgbox's
to track down the offending statement.

The last msgbox is after the final form show, and before the Exit Sub in
my
Sub Main. Guess what happened to me next?

When run under these circumstances in the IDE, the main form load event
fires as expected, AND THE FORM ACTIVATE EVENT DOESN'T!

SP7 anyone?
This could be my misunderstanding but I always thought that form activate
fires when your application was switched out to another then the application
window is made active again and become the front most window.

In the IDE I don't believe switching from one form to another to include the
VB editor constitute an application switch.
Oct 29 '06 #2

P: n/a
"David C. Barber" <da***@NOSPAMdbarber.com>'s wild thoughts
were released on Sat, 28 Oct 2006 12:29:38 -0700 bearing the
following fruit:
>I discovered an amazing hitch in VB6 SP6.

I run a Sub Main that shows a splash screen, initializes a number of items,
takes down the splash screen, and shows the main form.

While trying to track another problem that I couldn't run in the IDE because
this problem (an ADODB OLEDB connection to an SQL Database that runs fine in
Windows 2K, and blows up on the recordset open in XP) has to be run on
another machine without VS6 installed, I inserted a whole string of msgbox's
to track down the offending statement.

The last msgbox is after the final form show, and before the Exit Sub in my
Sub Main. Guess what happened to me next?

When run under these circumstances in the IDE, the main form load event
fires as expected, AND THE FORM ACTIVATE EVENT DOESN'T!

SP7 anyone?
OK, firstly it's not unusal to have a problem that doesn't
occur when running in the IDE.

Secondly, a messagebox is a very poor way to try and debug
it. I'm not in the least bit suprised that events aren't
firing as you might expect if your doing this.

Add line numbers to you code and log this information along
with the error. If you want to track program flow, log the
details to file. This way the program is more likely to flow
in the same way as your original compiled app. However
sometimes just adding one extra line of code to log somthing
can affect things.


Jan Hyde (VB MVP)

--
Did you hear about the self help group for compulsive talkers? It's called On & On Anon. (Doug Helsel)

Oct 30 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.