Error Checking in Excel
Thanks Thanks:  0
Likes Likes:  0
Results 1 to 3 of 3

Thread: Label Caption - Code

  1. #1
    New Member
    Join Date
    Mar 2002
    Location
    Paul
    Posts
    34
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hi all,

    I've been trying to have my form display a "Loading files...Please wait" message whilst it opens a file. However, the following code displays the label after it has opened the file (i.e. - too late!). How can I display the label before commencing the opening of the file?

    Any thoughts?? Many Thanks in anticipation.

    Cheers - Paul

    Private Sub loadsup_Click()
    lblwait.Visible = True
    lblwait.Caption = "Loading files...Please wait"
    ChDir "C:blah blah"
    Workbooks.Open Filename:="C:blah blahtest.xls"


  2. #2
    Board Regular
    Join Date
    Mar 2002
    Location
    Cincinnati, Ohio, USA
    Posts
    6,824
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hi Paul
    Use the UserForm.RePaint Method





    Private Sub loadsup_Click()
    lblwait.Visible = True
    lblwait.Caption = "Loading files...Please wait"
    UserForm1.Repaint
    Workbooks.Open Filename:="C:blah blahtest.xls"
    End Sub



    Replace UserForm1 with the name of your form.
    Tom

  3. #3
    New Member
    Join Date
    Mar 2002
    Location
    Paul
    Posts
    34
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Not sure how to edit initial post (answers on a postcard) but PROBLEM SOLVED.

    MANY THANKS!

    Cheers - Paul

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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