I have a winforms app written in Vs2005 Vb.Net, The setiings are to Enable
the application Framework and I defined a splashform. Works fine if no
errors occur. I do a checking on the mainform load event to make sure that
my database connectivity works OK. If it does not, I give the user a warning
message, but he can end up getting an unhandled exception that closes down
the app, which is what I want in that case. However when the app shuts down,
the splash screen remains visible. I think that it is running in its own
thread and it does not necessarely close down when the app closes.
I think best thing to do is to use the application events, see if the
splashscreen is still open and if it is, close it down. However I'm at a
loss on how to code this, and maybe there is another better way, I was
looking also for a property somewhere where you could set the max time the
splash screen would remain loaded whatever the case. But I could not find
it.
Any help would be appreciated
Bob 7 2858
Hello Bob, I was looking also for a property somewhere where you could set the max time the splash screen would remain loaded whatever the case. But I could not find it. Any help would be appreciated
What class are you using as your SplashForm? Can you post the namespace
and dll if you know it
--
Jared Parsons [MSFT] ja******@online .microsoft.com
Bob, I had a very similar problem and based on feedback I got from Microsoft
in the MSDN forums, it looks like you may be experiencing an confirmed bug
in the Application Framework. See here for details... http://forums.microsoft.com/MSDN/Sho...21737&SiteID=1
Basically, what I theorize is going on is that the Application Framework
will close the splash screen after it's done initializing the main startup
form. But if you cancel the creation of the startup form (say, because you
encountered a database error and want to shut down the application), the
startup form never completes its initialization. The Application Framework
is happily sitting there checking to see if the startup form is initialized,
finding that it's not, and happily waiting some more. Ad infinitum.
My solution? Unfortunately, because of this issue, I ended up not using the
Application Framework splash screen feature and managed the creation and
closing of my splash screen myself.
HTH
- Mitchell S. Honnert
"Bob" <bd*****@sgiims .com> wrote in message
news:OG******** *****@TK2MSFTNG P03.phx.gbl... I have a winforms app written in Vs2005 Vb.Net, The setiings are to Enable the application Framework and I defined a splashform. Works fine if no errors occur. I do a checking on the mainform load event to make sure that my database connectivity works OK. If it does not, I give the user a warning message, but he can end up getting an unhandled exception that closes down the app, which is what I want in that case. However when the app shuts down, the splash screen remains visible. I think that it is running in its own thread and it does not necessarely close down when the app closes. I think best thing to do is to use the application events, see if the splashscreen is still open and if it is, close it down. However I'm at a loss on how to code this, and maybe there is another better way, I was looking also for a property somewhere where you could set the max time the splash screen would remain loaded whatever the case. But I could not find it.
Any help would be appreciated
Bob
Yeah, you're right thats exactly what is happening.
You got a code snippet for managing the splash form yourself?
I would grately appreciate it.
Bob
"Mitchell S. Honnert" <ne**@REMhonner tOVE.com> wrote in message
news:ur******** ******@TK2MSFTN GP02.phx.gbl... Bob, I had a very similar problem and based on feedback I got from Microsoft in the MSDN forums, it looks like you may be experiencing an confirmed bug in the Application Framework. See here for details...
http://forums.microsoft.com/MSDN/Sho...21737&SiteID=1
Basically, what I theorize is going on is that the Application Framework will close the splash screen after it's done initializing the main startup form. But if you cancel the creation of the startup form (say, because you encountered a database error and want to shut down the application), the startup form never completes its initialization. The Application Framework is happily sitting there checking to see if the startup form is initialized, finding that it's not, and happily waiting some more. Ad infinitum.
My solution? Unfortunately, because of this issue, I ended up not using the Application Framework splash screen feature and managed the creation and closing of my splash screen myself.
HTH
- Mitchell S. Honnert
"Bob" <bd*****@sgiims .com> wrote in message news:OG******** *****@TK2MSFTNG P03.phx.gbl...I have a winforms app written in Vs2005 Vb.Net, The setiings are to Enable the application Framework and I defined a splashform. Works fine if no errors occur. I do a checking on the mainform load event to make sure that my database connectivity works OK. If it does not, I give the user a warning message, but he can end up getting an unhandled exception that closes down the app, which is what I want in that case. However when the app shuts down, the splash screen remains visible. I think that it is running in its own thread and it does not necessarely close down when the app closes. I think best thing to do is to use the application events, see if the splashscreen is still open and if it is, close it down. However I'm at a loss on how to code this, and maybe there is another better way, I was looking also for a property somewhere where you could set the max time the splash screen would remain loaded whatever the case. But I could not find it.
Any help would be appreciated
Bob
And yeah I saw what they suggest as solution in the linkyou gave me, I'll
give that a shot also. THANKS.
"Mitchell S. Honnert" <ne**@REMhonner tOVE.com> wrote in message
news:ur******** ******@TK2MSFTN GP02.phx.gbl... Bob, I had a very similar problem and based on feedback I got from Microsoft in the MSDN forums, it looks like you may be experiencing an confirmed bug in the Application Framework. See here for details...
http://forums.microsoft.com/MSDN/Sho...21737&SiteID=1
Basically, what I theorize is going on is that the Application Framework will close the splash screen after it's done initializing the main startup form. But if you cancel the creation of the startup form (say, because you encountered a database error and want to shut down the application), the startup form never completes its initialization. The Application Framework is happily sitting there checking to see if the startup form is initialized, finding that it's not, and happily waiting some more. Ad infinitum.
My solution? Unfortunately, because of this issue, I ended up not using the Application Framework splash screen feature and managed the creation and closing of my splash screen myself.
HTH
- Mitchell S. Honnert
"Bob" <bd*****@sgiims .com> wrote in message news:OG******** *****@TK2MSFTNG P03.phx.gbl...I have a winforms app written in Vs2005 Vb.Net, The setiings are to Enable the application Framework and I defined a splashform. Works fine if no errors occur. I do a checking on the mainform load event to make sure that my database connectivity works OK. If it does not, I give the user a warning message, but he can end up getting an unhandled exception that closes down the app, which is what I want in that case. However when the app shuts down, the splash screen remains visible. I think that it is running in its own thread and it does not necessarely close down when the app closes. I think best thing to do is to use the application events, see if the splashscreen is still open and if it is, close it down. However I'm at a loss on how to code this, and maybe there is another better way, I was looking also for a property somewhere where you could set the max time the splash screen would remain loaded whatever the case. But I could not find it.
Any help would be appreciated
Bob
On Wed, 28 Jun 2006 16:49:21 -0400, "Bob" <bd*****@sgiims .com> wrote: I have a winforms app written in Vs2005 Vb.Net, The setiings are to Enable the application Framework and I defined a splashform. Works fine if no errors occur. I do a checking on the mainform load event to make sure that my database connectivity works OK. If it does not, I give the user a warning message, but he can end up getting an unhandled exception that closes down the app, which is what I want in that case. However when the app shuts down, the splash screen remains visible. I think that it is running in its own thread and it does not necessarely close down when the app closes. I think best thing to do is to use the application events, see if the splashscreen is still open and if it is, close it down. However I'm at a loss on how to code this, and maybe there is another better way, I was looking also for a property somewhere where you could set the max time the splash screen would remain loaded whatever the case. But I could not find it.
Any help would be appreciated
Bob
With "Use SplashFrom" enabled, the SplashForm is the first object that
loads. If I want to check prerequisites (like OS) and do not want the
app to run if a condition is not met, I put that code in the
SpashForm:
Public Sub New()
If some condition is not valid then
MessageBox.Show ("Condition not met")
End
End If
' This call is required by the Windows Form Designer.
InitializeCompo nent()
End Sub
In the above, the SplashForm and app never load if the condition is
not met.
If I want to test for a condition (like Internet connectivity), warn
the user, but not prevent the app from running, I do that in the
MainForm's Shown Event.
Gene
Thanks Gene, those are good ideas.
I'll get used to this .net stuff yet :-)
Bob
"gene kelley" <ok**@by.me> wrote in message
news:mh******** *************** *********@4ax.c om... On Wed, 28 Jun 2006 16:49:21 -0400, "Bob" <bd*****@sgiims .com> wrote:
I have a winforms app written in Vs2005 Vb.Net, The setiings are to Enable the application Framework and I defined a splashform. Works fine if no errors occur. I do a checking on the mainform load event to make sure that my database connectivity works OK. If it does not, I give the user a warning message, but he can end up getting an unhandled exception that closes down the app, which is what I want in that case. However when the app shuts down, the splash screen remains visible. I think that it is running in its own thread and it does not necessarely close down when the app closes. I think best thing to do is to use the application events, see if the splashscree n is still open and if it is, close it down. However I'm at a loss on how to code this, and maybe there is another better way, I was looking also for a property somewhere where you could set the max time the splash screen would remain loaded whatever the case. But I could not find it.
Any help would be appreciated
Bob
With "Use SplashFrom" enabled, the SplashForm is the first object that loads. If I want to check prerequisites (like OS) and do not want the app to run if a condition is not met, I put that code in the SpashForm:
Public Sub New() If some condition is not valid then MessageBox.Show ("Condition not met") End End If ' This call is required by the Windows Form Designer. InitializeCompo nent() End Sub
In the above, the SplashForm and app never load if the condition is not met.
If I want to test for a condition (like Internet connectivity), warn the user, but not prevent the app from running, I do that in the MainForm's Shown Event.
Gene
*scratches his head* Ugh! you're kidding right? *stomache churns* Glad I'm
finding this out NOW rather than later. I've just gotten done adding some
setup code in the initializing of my main form. It detects if the app has
been run before or not, and if not, runs the setup wizard... so... it sounds
like I need to shut off the application framework and do it the old-fashioned
way.
They way I'd like to see it run: splash happens. Main form loads and
displays, splash goes away, setup wizard appears. ... On the other hand, it
makes sense....
-ca
"Mitchell S. Honnert" wrote: Bob, I had a very similar problem and based on feedback I got from Microsoft in the MSDN forums, it looks like you may be experiencing an confirmed bug in the Application Framework. See here for details...
http://forums.microsoft.com/MSDN/Sho...21737&SiteID=1
Basically, what I theorize is going on is that the Application Framework will close the splash screen after it's done initializing the main startup form. But if you cancel the creation of the startup form (say, because you encountered a database error and want to shut down the application), the startup form never completes its initialization. The Application Framework is happily sitting there checking to see if the startup form is initialized, finding that it's not, and happily waiting some more. Ad infinitum.
My solution? Unfortunately, because of this issue, I ended up not using the Application Framework splash screen feature and managed the creation and closing of my splash screen myself.
HTH
- Mitchell S. Honnert
"Bob" <bd*****@sgiims .com> wrote in message news:OG******** *****@TK2MSFTNG P03.phx.gbl...I have a winforms app written in Vs2005 Vb.Net, The setiings are to Enable the application Framework and I defined a splashform. Works fine if no errors occur. I do a checking on the mainform load event to make sure that my database connectivity works OK. If it does not, I give the user a warning message, but he can end up getting an unhandled exception that closes down the app, which is what I want in that case. However when the app shuts down, the splash screen remains visible. I think that it is running in its own thread and it does not necessarely close down when the app closes. I think best thing to do is to use the application events, see if the splashscreen is still open and if it is, close it down. However I'm at a loss on how to code this, and maybe there is another better way, I was looking also for a property somewhere where you could set the max time the splash screen would remain loaded whatever the case. But I could not find it.
Any help would be appreciated
Bob This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Bill |
last post by:
Problem 1)
Any ideas on how I would get a splash screen to appear for a certain
amount of time when I open a database - it's to display a text based
disclaimer message.
I know about message boxes in VB but I don't my users having to click
on an OK buttone each time this appears.
Problem 2)
|
by: John |
last post by:
Hi
I have created a splash form with no border. When I try to open this form in
my main form using DoCmd.OpenForm "Splash", , , , , acDialog, the splash
form opens with a form border. If I use DoCmd.OpenForm "Splash" then splash
form opens without a border as desired but then the main form starts to
appear before splash form has gone.
How can I get the splash form to open without a border?
|
by: steve |
last post by:
Hi All
I have set a splash screen form as the application splash screen in VB.net
2005
I t runs fine but stays on top when my login screen appears
How can I shut the splash screen down when the login screen is shown
Attempts to close it from the application main form results in error message
|
by: will_456 |
last post by:
In vb2005 Express:
In My Project Application Splash Screen I have selected my splash
screen form.
The form opens on project startup but closes immediately before anyone would
have time to read it. I presume it only stays visible while the main form
initialises.
This is not long enough but I can't see how to slow it down.
Should I set the splash screen using the Application settings or go back to
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |