SPONSORS:






User Tag List

Results 1 to 6 of 6

Thread: Splash problem

  1. #1
    Junior Member
    Join Date
    May 2002
    Posts
    5
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Splash problem

    I have a problem - perhaps someone else has come accross the same thing?

    I think the problem is connected to a splash screen.

    The program that I am testing (pure VC++ so no extensions used) takes a while to boot (up to 10 secnods) and is preceeded by a splash screen. I have wInvokeTimeout set nice and long (30 sec) so timeout should not be an issue. After reading the help file on handling log in windows which told me 'Note You do not need to use this procedure for splash screens, which disappear on their own.' I duly left it alone...

    About 40% of the time Silk starts the application properly and the tests go ahead.

    Most of the time however the instant the splash screen appears DefaultBaseState goes into its routine of building a close windows list, closes the splash screen, then complains that the application's main window is not open.

    I've tried setting wStartup to point to a definition of the splash window but this does not help.

    I'm just about to start tracing through DefaultBaseState to see what's going on - but I wondered if anyone else had come accross this?

    Many thanks for any comments,

    Richard.

  2. #2
    Member
    Join Date
    Oct 2001
    Posts
    93
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Splash problem

    Try changing the invoke method for your application so that it looks for a splash screen before your mainwin. Something like this may help:

    Invoke ()
    myMainWin.Start(sCmdLine)

    while SplashScreen.Exists (1)
    Sleep (1)

    myMainWin.SetActive ()

    ------------------
    Paul Tucker
    Merit AT
    www.merit-at.com
    Paul Tucker
    Merit AT
    www.merit-at.com

  3. #3
    Junior Member
    Join Date
    May 2002
    Posts
    5
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Splash problem

    Thanks for the tip. I was going to look at a custom Invoke() as a solution a bit later. At the moment I'm trying to work out where DefaultBaseState is going wrong.

    I'll try that this afternoon.

    Thanks again.

    Richrd

    ------------------

  4. #4
    Senior Member
    Join Date
    Aug 1999
    Location
    Cambridge, UK
    Posts
    470
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Splash problem

    Is your splash screen a childwin of your aut's mainwin by any chance? i.e. in your recorded window declaration for the splash screen, does it include the line "parent foo" (where 'foo' is the name of your mainwin). I could imagine that confusing defaultbasestate.

    ------------------

  5. #5
    Junior Member
    Join Date
    May 2002
    Posts
    5
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Splash problem

    Vince - not sure - when the splash creen definition didn't work I deleted it. I'll try again both defined as child and as a separate window.

    Thanks for the tip.

  6. #6
    Junior Member
    Join Date
    May 2002
    Posts
    5
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Splash problem

    Thanks for the help folks.

    In case you're interested - the problem stems for the fact that the splash screen dissapears after a certain timeout, or can be dismissed by the user. This can result in a few seonds lag until the main application window appears. (This sounds like an odd way to code a splash screen to me - but oh well...). During this time there is apparrently no window present.

    Unfortunately during this time the main window returns true from Exists() (I can only assume it is present but invisible).

    I found a reasonable solution by building a delay loop into Invoke() using IsActive() (The print()s are for debug purposes and will soon dissapear.)

    [-] Invoke()
    [ ] derived::Invoke()
    [ ] print("wQP Invoked")
    [ ]
    [-] while(!wQP.IsActive())
    [ ] print("Waiting...")
    [ ] sleep(1)
    [ ] print("wQP::Invoke() exiting.")

    I might try changing IsActive() for IsVisible() - we'll see.

    Thanks again for the advice.

    Richard.

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 02:14 PM.

Copyright BetaSoft Inc.