adding a splash screen to an existing user form app

mortgageman

Well-known Member
Joined
Jun 30, 2005
Messages
2,015
I found this which showed me how to make a splash screen in Excel:
http://www.youtube.com/watch?v=WPUiSiDMkkU

What I would like to know is how to make a splash screen that shows itself for a few seconds - but then I want my other user form (my main application) to start by itself.

Thanks in advance

Gene Klein
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
Just on the face of it without testing, have you tried to simply place the line

myUserForm.Show (change the name to whatever your userform name is)

after her "KillTheForm" execution but before End Sub
 
Upvote 0
Just on the face of it without testing, have you tried to simply place the line

myUserForm.Show (change the name to whatever your userform name is)

after her "KillTheForm" execution but before End Sub

I guess this is dumb - but does that mean I would have to name my splash-screen user form a different name then userform1 to avoid name conflicts?


Gene Klein
 
Upvote 0
Well, yes but you'd need to have a unique name for each userform in your workbook anyway, splash screen or not.
 
Upvote 0
Just on the face of it without testing, have you tried to simply place the line

myUserForm.Show (change the name to whatever your userform name is)

after her "KillTheForm" execution but before End Sub

Here is what I tried:


Code:
Private Sub UserForm_Initialize()
Application.Goto Reference:="lookaway"
UserForm2.Show
TimeValue ("00:00:05"), "KillTheForm"
<rest of my original code that worked without a problem before>
end sub
 
Private Sub KillTheForm()
Unload UserForm2
End Sub


Here is the error I got:
Wrong number of arguments or invalid property assignment

Thanks in advance

Gene Klein
 
Upvote 0
Hello,

Without having watched the video, have you seen J-Walk's page on this?

http://j-walk.com/ss/excel/tips/tip39.htm

You want the OnTime Method.

Code:
Private Sub UserForm_Initialize()
Application.Goto Reference:="lookaway"
UserForm2.Show
With UserForm1
****code that worked when I only had one user form****
 Private Sub UserForm_Activate()
    Application.OnTime Now + TimeValue("00:00:05"), "KillTheForm"
End Sub
Private Sub KillTheForm()
Unload UserForm2
End Sub

Ok - this is "working" in the sense that I do not get an error message, but it is not "splashing" - i.e. I have to click the x on the top of the (first) form to make it go away. After I do, the second form correctly shows up.

Help?

Gene Klein
 
Upvote 0
Hello, try this, place the following in the UserForm1 Module:

Code:
Private Sub UserForm_Initialize()
Application.OnTime Now + TimeValue("00:00:05"), _
    "KillTheForm"
End Sub

And place this in a Normal module:

Code:
Private Sub KillTheForm()
UserForm1.Hide: Unload UserForm1
Load UserForm2: UserForm2.Show
End Sub
It's a bit of a matter of naming conventions, location and order of operations. Change the Form's names as appropriate.
 
Upvote 0
Hello, try this, place the following in the UserForm1 Module:

Code:
Private Sub UserForm_Initialize()
Application.OnTime Now + TimeValue("00:00:05"), _
    "KillTheForm"
End Sub

And place this in a Normal module:

Code:
Private Sub KillTheForm()
UserForm1.Hide: Unload UserForm1
Load UserForm2: UserForm2.Show
End Sub
It's a bit of a matter of naming conventions, location and order of operations. Change the Form's names as appropriate.

Perfect. Thanks

Gene Klein
 
Upvote 0

Forum statistics

Threads
1,213,487
Messages
6,113,937
Members
448,534
Latest member
benefuexx

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top