+ Reply to Thread
Results 1 to 5 of 5

Unloading a Userform unloads another as well??

  1. #1
    Registered User
    Join Date
    11-11-2013
    Location
    Fareham
    MS-Off Ver
    Excel 2003
    Posts
    5

    Unloading a Userform unloads another as well??

    Help please

    I have Userform1 that I use to add data to a workbook, within this Userform is a Cmdbutton that shows another Userform2 that is used to save worksheets as PDF. On completion Userform2 Unloads, however this action also closes Userform1. I am using
    Please Login or Register  to view this content.
    to unload the Userform. I have also tried using
    Please Login or Register  to view this content.
    but this opens an empty userform, and not the populated one.

    Any Ideas??

    Thanks

    Steve

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2504
    Posts
    13,640

    Re: Unloading a Userform unloads another as well??

    Administrative note

    Still using XL2003 as indicated in your profile?
    If not,perhaps update your profile as necessary to properly reflect the exact version(s) of Excel your question relates to? Members tailor answers based on your Excel version.
    Thanks

  3. #3
    Forum Expert romperstomper's Avatar
    Join Date
    08-13-2008
    Location
    England
    MS-Off Ver
    365, varying versions/builds
    Posts
    22,023

    Re: Unloading a Userform unloads another as well??

    I suggest you attach the workbook as it's a lot easier than trying to fathom all the possible causes of this behaviour. I assume that Userfrom1 was a typo.
    Everyone who confuses correlation and causation ends up dead.

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Unloading a Userform unloads another as well??

    Hi,

    Is there any code in the Userform2 Terminate event?

    The easiest way to understand this is for you to upload the workbook so that we can see the problem in context.

    Since Userform1 is closed then anything you captured in list/combo boxes will of course have disappeared and will not show the next time you open the form.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  5. #5
    Registered User
    Join Date
    11-11-2013
    Location
    Fareham
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Unloading a Userform unloads another as well??

    All

    Thanks for your replies, Richards got me thinking, I have code running when the terminate event is triggered. I have now moved this out of the main code and it seems to now work.

    Thanks all

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] UserForm not unloading properly
    By Sintek in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-25-2016, 09:54 AM
  2. UserForm CommandButton not unloading
    By puzzlelover22 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-12-2016, 10:24 PM
  3. VLookup for when unloading information from Userform
    By kksf in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-28-2013, 09:50 AM
  4. [SOLVED] Hiding/Unloading Userform
    By fbexel in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-17-2012, 06:06 PM
  5. Offset Positions When Unloading Userform
    By liam_bettinson in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 09-01-2011, 06:40 AM
  6. unloading userform before Inputbox
    By 4sharkfins in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-11-2009, 11:33 PM
  7. Getting error unloading Userform??
    By Ed in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-30-2005, 08:05 PM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1