Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Label not painting/refreshing when form displays.
Message
 
 
À
16/08/2005 11:09:32
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Divers
Thread ID:
01041143
Message ID:
01041360
Vues:
24
Mary,

Try to flip visible property. E.g after you set the caption do
this.lbl.visible=.f.
this.lbl.visible = .t.
>Here is the code of the splash screen Init:
>
>
>LPARAMETERS pcSplash
>
>IF VARTYPE(pcSplash) == "C" AND NOT EMPTY(pcSplash)
>	THISFORM.lblSplash.Caption = pcSplash
>ENDIF
>
>* Show in upper half of screen, so that if an error box appears in middle of screen
>* it is not covered up by this.
>THISFORM.Left = INT((SYSMETRIC(1) - THISFORM.Width)/2)
>THISFORM.Top = INT((SYSMETRIC(2) - THISFORM.Width)/3)
>
>RETURN .T.
>
>
>No matter what I add after setting the label caption, it does not display. However, if I put a DOEVENTS after the frmSpplash.Show() (in the calling program), it shows.
>
>I tried recreating this as a separate little sample program, and cannot recreate. I hate having to call a DOEVENTS from the calling program (since I don't see why that is any different than doing it right inside the form).
>
>OK, tried one more thing...a DOEVENTS FORCE in the Activate event of the form. It worked. Lable displays perfectly right as soon as form displays. DOEVENTS FORCE in the Show() event did NOT make it display. This is weird, but it works now. I can add this to all our splash forms in the Activate and we should be OK. The DOEVENTS FORCE does a batter job than DOEVENTS too, so thank you for that tip!
>
>Thanks,
>JoeK
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform