hide/show problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • alcapoontje
    New Member
    • Jul 2006
    • 10

    hide/show problem

    i'm making somekind of pad with commandbuttons and different forms.
    -> when you click the cmd on form1, form1 is hidden and form 2 is showed
    when you click the cmd on form2, form2 is hidden and form3 is showed
    -> the problem: if you click the cmd on form 3 normally form1 has to be showed and form3 has to be hidden. but when i do this i receive an error

    when you think you can help me and you need the program, i'll mail it to you
    (warning: it is maid is visual basic excell)



    peter

    (i'm learning VB on my own, sow don't be mad when you think this is a ridiculous question.)
  • sashi
    Recognized Expert Top Contributor
    • Jun 2006
    • 1749

    #2
    Hi there,

    i assume the sample code below should work for fine.. good luck my fren.. :)

    code for cmd on form1
    Code:
        form1.hide
        load form2
        form2.show
    code for cmd on form2
    Code:
        form2.hide
        load form3
        form3.show

    Comment

    • alcapoontje
      New Member
      • Jul 2006
      • 10

      #3
      yep, now it worked
      thanx

      Comment

      • Ali Rizwan
        Banned
        Contributor
        • Aug 2007
        • 931

        #4
        Originally posted by alcapoontje
        i'm making somekind of pad with commandbuttons and different forms.
        -> when you click the cmd on form1, form1 is hidden and form 2 is showed
        when you click the cmd on form2, form2 is hidden and form3 is showed
        -> the problem: if you click the cmd on form 3 normally form1 has to be showed and form3 has to be hidden. but when i do this i receive an error

        when you think you can help me and you need the program, i'll mail it to you
        (warning: it is maid is visual basic excell)



        peter

        (i'm learning VB on my own, sow don't be mad when you think this is a ridiculous question.)
        Hello buddy
        just add this command to form 1

        private sub ()

        form2.show
        unload me

        end sub

        add in form 2

        private sub ()

        form3.show
        unload me

        end sub

        add in form 3

        private sub ()

        form1.show
        unload me

        end sub

        it will work properly

        Comment

        Working...