Results 1 to 2 of 2

Thread: Unbelievable !!

  1. #1
    Join Date
    Nov 2003
    Location
    Bucharest, Romania
    Posts
    17

    Unhappy Unanswered: Unbelievable !!

    Hi

    I have a form with 2 arrays : command1 and label1 and some code, which says :
    ...
    label1(ind).visible = command1(ind).visible
    ....

    with ind = some index.

    Despite this, label1 NEVER becomes visible, because when sampled, command1.visible ALWAYS returns the value it was set at Design Time. So, after banging my head against various objects, I tried this :
    ...
    command1(ind).visible = true
    if command1(ind).visible then <some code>
    ...

    Guess what ? The <some code> never executes !!! Also, when using the Watch Window, the .Visible property of command1 never changes - it stays the way I set it at Design Time !

    Is this Christmas or Halloween ?

    Have some clue ?

  2. #2
    Join Date
    Oct 2002
    Location
    Argentina
    Posts
    72

    Re: Unbelievable !!

    Try moving your code to the Form_Activate method

    Originally posted by mike_abc
    Hi

    I have a form with 2 arrays : command1 and label1 and some code, which says :
    ...
    label1(ind).visible = command1(ind).visible
    ....

    with ind = some index.

    Despite this, label1 NEVER becomes visible, because when sampled, command1.visible ALWAYS returns the value it was set at Design Time. So, after banging my head against various objects, I tried this :
    ...
    command1(ind).visible = true
    if command1(ind).visible then <some code>
    ...

    Guess what ? The <some code> never executes !!! Also, when using the Watch Window, the .Visible property of command1 never changes - it stays the way I set it at Design Time !

    Is this Christmas or Halloween ?

    Have some clue ?

Posting Permissions

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