Results 1 to 6 of 6

Thread: Show/Hide a form in form_load (Resolved)

Threaded View

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Mar 2004
    Location
    Victoria, Australia
    Posts
    23

    Show/Hide a form in form_load (Resolved)

    I have two forms - frmmain, and form1

    Under frmmain, I'm using a If/Then/Else statement checking a variable value.
    Frmmain is the startup form.

    VB Code:
    1. Dim form1 as new form1
    2.  
    3. If Val = "1" Then
    4. 'do nothing
    5. Else
    6. form1.visible = True
    7. frmmain.visible = False
    8. End If

    form1 will always show, but frmmain won't hide. I've tested this using just one form and just putting me.visible = false. I've tried me.hide, I've tried putting the code behind a timer and enabling the timer from form_load, I've tried calling a new sub from form_load, but NOTHING I do seems to work.

    Does anyone know what I'm doing wrong?
    Last edited by DestructoX; Mar 23rd, 2004 at 01:33 AM.
    Logic is a systematic way of coming to the wrong conclusion with confidence.

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