Results 1 to 3 of 3

Thread: *** URGENT *** Changing Labels while running

  1. #1

    Thread Starter
    Member
    Join Date
    Mar 2000
    Posts
    57

    Unhappy

    I need to change the font of labels while my program runs. My problem is that I don't know the name until an action happens. What I have tried ......


    "lbl_" & txt_name.text & ".ForeColor=&H80&"

    example of what this should then read is (lbl_MODEL_DESC.FORECOLOR=&H80)

    ...but I get syntax errors.

    Help needed urgently .
    Thanks
    Bob


  2. #2
    Hyperactive Member tumblingdown's Avatar
    Join Date
    Mar 2000
    Posts
    362
    Two ways:

    Form1.Controls("Label1").ForeColor = &H80&

    or you could have your labels in an array...
    Label1(Index)").ForeColor = &H80&



    td.


    "One logical slip and an entire scientific edifice comes tumbling down." - Robert M. Pirsig


    [email protected]

    "but if Einstein is right and God is in the details, reality requires that we sometimes get religion." - Scott Meyers.

  3. #3

    Thread Starter
    Member
    Join Date
    Mar 2000
    Posts
    57

    Wink

    Thanks ThumblingDown, that Controls option is spot on.









    That was A1 Sharon !!!!!

Posting Permissions

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



Click Here to Expand Forum to Full Width