Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Splash Screen is not 'Splashing'
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00537883
Message ID:
00537901
Views:
12
This message has been marked as the solution to the initial question of the thread.
The way I call my splash screen is:
poSplash = .NULL.
poSplash =  NEWOBJECT('c40splash','c40baseforms.vcx', '', pcAppName, pcAppVersion, pcAppAuthor, pcAppCompany, pcAppCopyRight, pcAppTradeMark, pcAppLogo)
IF VARTYPE(poSplash) = "O"
  pnSeconds = SECONDS()
  poSplash.SHOW()
ENDIF
Then when I am done setting up I call the procedure to shut it down ensuring the time elapsed is ok
        * Close our splash screen by calling procedure at end of this module
        * and ensure that the screen is maximized and shown
        DO Shutdown_Splash_Screen
Procedure code is:
*==============================================================================
* SHUTDOWN_SPLASH_SCREEN
*
* This will close out the spalsh screen
*==============================================================================

PROCEDURE Shutdown_Splash_Screen

* Release our splash screen if it is time
IF VARTYPE(poSplash) = "O"
  IF SECONDS() INKEY(pnAppDelay-(SECONDS()-pnSeconds),"MH")
  ENDIF
  poSplash.RELEASE()
  poSplash = .NULL.
  _SCREEN.WINDOWSTATE = 2
  _SCREEN.VISIBLE = .T.
ENDIF
RELEASE poSplash, pnSeconds
>I've created a few classes for some common tasks within a database application (User Information, System Configuration, User Management, About Box, etc). I have a little problem with my splash screen (that is a class too), it is not showing up. Here is the sequence of steps I make in the system startup:
>
>** MAIN PROGRAM
>* Do some sets (classlib, etc)
>
>* Create the splash object
>
>oSplash = NewObject("splash","general_classes")
>oSplash.Show()
>
>** oSplash.SHOW()
>LPARAMETERS nStyle
>
>DODEFAULT() && Don't know if I need to place this here
>
>&& Splash Screen should be displayed for 1,5 seconds, then create the other && objects and then release
>
>ThisForm.Timer1.Interval = 1500
>
>READ EVENTS && Start receiving windows events
>
>** oSplash.Timer1.Timer()
>
>This.Interval = 0 && Just need to show the Splash Screen once
>
>ThisForm.Startup() && Call the method that creates all the other objects
>
>----------
>Here are the properties of the splash class (form based)
>
>AllwaysOnTop = .T.
>AutoCenter = .T.
>BorderStyle = 1 (Fixed Single)
>Caption = (None)
>Closable = .F.
>ControlBox = .F.
>Desktop = .T.
>LockScreen = .F.
>MDIForm = .F.
>MaxButton = .F.
>MinButton = .F.
>Movable = .T.
>ShowWIndow = 2 (As Top Level)
>TitleBar = 0 (Off)
>Visible = .T.
>WindowState = 0 (Normal)
>WindowType = 1 (Modal)
>
>I don't know why the form isn't showing up (it is instantiated, and all code is executed).
>
>Based on past experiences when i asked something on the UT, I'm sure that my problem is something very stupid that i haven't noticed. :)
>
>Thanks again,
>
>Alonso
Bret Hobbs

"We'd have been called juvenile delinquents only our neighborhood couldn't afford a sociologist." Bob Hope
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform