• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 315
  • Last Modified:

Label will not load on form

I have the following code

Form7.show;
sleep(3000);
ScaffoldHeaderTable.Active:=True;
ADOTable8.Active:=True;
ScaffoldBillingTable.Active:=True;
ScaffoldHeaderExportTable.Active:=True;
TotalViewScaffoldTable.Active:=True;
ScaffoldHeaderDateTable.Active:=True;
AllScaffoldTable.Active:=True;
ScaffoldCOTable.Active:=True;
ScaffoldPOTable.Active:=True;
Form7.Close;



Form 7 is just a form with a label on it that says please wait (because it takes so long for these tables to become active)

when form 7 is displayed it only shows a blank fomr with out my lable

is there a better way to do this ? I put the sleep to see if that would give it enough time to load but that still does not work. And I am slowing the program down even more


0
jfgrayiii
Asked:
jfgrayiii
  • 2
  • 2
1 Solution
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
What language is that?...
0
 
jfgrayiiiAuthor Commented:
Delphi 7 sorry about that
0
 
jfgrayiiiAuthor Commented:
I posted this in the wrong section
0
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
I don't know Delphi7 but typically the Sleep() call puts your app COMPLETELY to sleep...meaning it can't even repaint itself.

In VB.Net() I would do this:

    Form7.Show()
    Application.DoEvents()

To force the app to show itself and completely paint before moving on.

Also, you said:

     (because it takes so long for these tables to become active)

Sounds like you should be loading your tables on another thread.

Hope you get more solid answers in the Delphi area...  =)

0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now