+ Reply to Thread
Results 1 to 6 of 6

The userform doesn't seem to unload although I am using unload me line.

  1. #1
    Forum Contributor
    Join Date
    02-20-2009
    Location
    bristol
    MS-Off Ver
    Excel 2003
    Posts
    883

    The userform doesn't seem to unload although I am using unload me line.

    Now when the userform UF1MadHatter gets uploaded then a message is displayed "This Application is for Editing and Exiting Batches in the MI only.Do you wish to continue or not". If users press Yes then FrmDate gets displayed otherwise application is closed.

    When the users press SAVE button on the UF1MadHatter form then data gets updated in the table. But the userform UF1MadHatter still appears on the screen and upon that userform again message appears "This Application is for Editing and Exiting Batches in the MI only.Do you wish to continue or not". If users press Yes then FrmDate gets displayed upon the other form but in actual I want to unload the userform UF1MadHatter when the user press Save button and the message should display.

    I have written unload me and UF1Madhatter.show lines on the SAVE button but it doesn't seem to work. Any help would be much appreciated.

    Workbook open event, following code is written.
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    The following code is written in UF1MadHatter Save button.

    Please Login or Register  to view this content.

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

    Re: The userform doesn't seem to unload although I am using unload me line.

    I assume the second code is actually in FrmDate since otherwise you're just unloading and reloading the same form?
    Everyone who confuses correlation and causation ends up dead.

  3. #3
    Forum Contributor
    Join Date
    02-20-2009
    Location
    bristol
    MS-Off Ver
    Excel 2003
    Posts
    883

    Re: The userform doesn't seem to unload although I am using unload me line.

    Romperstomper, The second code is also in the same form. The thing is when workbook gets opened then the userform UF1MadHatter gets displayed. When its Save button is clicked then I want to it initialze the same way it gets intialized when the workbook is opened but its not doing that way. I am not sure what is causing the problem?

    Thanks

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

    Re: The userform doesn't seem to unload although I am using unload me line.

    Try replacing this:
    Please Login or Register  to view this content.
    with:
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    02-20-2009
    Location
    bristol
    MS-Off Ver
    Excel 2003
    Posts
    883

    Re: The userform doesn't seem to unload although I am using unload me line.

    Thanks romperstomper. Call userform_Intialize worked. But still on some textboxes i get error message like "can't move focus to control because its either invisible,not enabled" etc..

    When the workbook is opened then this userform gets loaded fine and i am able to type values in all the textboxes. But then when i press SAVE then with the use of call userform_Initialize , it gets loaded fine but i can't type values in all of the textboxes as i get that error message in some of them. So why it works fine the very first time it gets intialized and after clicking on save button , it doesn't.

    i hope you can help me in this.

    Regards,

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

    Re: The userform doesn't seem to unload although I am using unload me line.

    Which line gives you the error?

+ 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. Unload all userform
    By danjim02 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-06-2013, 12:13 PM
  2. [SOLVED] userform will not unload with unload me
    By cfinch100 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-24-2013, 12:09 PM
  3. ontime does not unload my userform
    By st0kvis in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-07-2010, 08:11 AM
  4. How do you unload only the top UserForm?
    By skysurfer in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 04-08-2010, 11:18 PM
  5. Unload Userform doesn't work here - why?
    By rammieib in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-23-2006, 09:55 AM

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