Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21906

Can't see images or labels on my form

$
0
0
HI,

I have this code when it runs it opens a blank form (no image or labels) until after my code is done.

I want the form to show and label to say "Running" then label changes when completed.

Right now, on form load it opens a blank form and then adds my labels and image only when it's done.


Code:

Private Sub Form_Load()
       
    Form1.Visible = True
    Form1.Image1.Visible = True
    Form1.Label1.Caption = "Starting Import"
    Form1.Command1.Visible = False
       
   
 
  Dim fso As New FileSystemObject

    fso.CopyFile "\\WSIPR2\GSAP\TES_REMOTE\ITITES\ITIDATA\Ultidata.mdb", "\\GSDCSHR01\gsap\TES_Remote\ITITES\ITIDATA\Ultidata.mdb"
       
  If Dir("\\GSDCSHR01\gsap\TES_Remote\ITITES\ITIDATA\Ultidata2.mdb") <> "" Then Kill _
        "\\GSDCSHR01\gsap\TES_Remote\ITITES\ITIDATA\Ultidata2.mdb"
        DBEngine.CompactDatabase "\\GSDCSHR01\gsap\TES_Remote\ITITES\ITIDATA\Ultidata.mdb", "\\GSDCSHR01\gsap\TES_Remote\ITITES\ITIDATA\Ultidata2.mdb"

  Label2.Caption = "Finished Compact and Repair of MDB Files on GSDCSHR01"
  Unload Me
End Sub


Viewing all articles
Browse latest Browse all 21906

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>