Consulting

Results 1 to 3 of 3

Thread: Ending a form

  1. #1
    VBAX Contributor Daxton A.'s Avatar
    Joined
    Jun 2004
    Location
    Biloxi, Mississippi
    Posts
    143
    Location

    Ending a form

    What I'm trying to do is to end a form but not end the program. Now, I know about hiding a form but, that's not what I need from Excel. What I have is two forms. First the original form pops up and whenever the user selects a certain row then the second form pulls up with the option to go back to the original form after you are finished using the second form. Now, I have the .Hide property originally used but that gives me problems when I go back to the form. I tried the visible property but it says that access is restricted. Can some help be provided?

    Thanks

  2. #2
    Administrator
    VP-Knowledge Base
    VBAX Grand Master mdmackillop's Avatar
    Joined
    May 2004
    Location
    Scotland
    Posts
    14,478
    Location
    Try "Unload UserForm1"
    MVP (Excel 2008-2010)

    Post a workbook with sample data and layout if you want a quicker solution.


    To help indent your macros try Smart Indent

    Please remember to mark threads 'Solved'

  3. #3
    VBAX Mentor asingh's Avatar
    Joined
    Jul 2005
    Posts
    307
    Location
    you could try...


    form1.hide
    unload form1
    set form1 = nothing


    this will completely kill the instance of form1...so if u use

    form1.show

    after the above mentioned...it will show form1 is as it coded in its form_activate event...


    regards Asingh

Posting Permissions

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