+ Reply to Thread
Results 1 to 12 of 12

if worksheet called from menu userform is minimised menu userform disappears - can this be

  1. #1
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    if worksheet called from menu userform is minimised menu userform disappears - can this be

    As above... menu userform works well until a worksheet within the workbook is called my the menu and viewed. Worksheet cannot be "closed" because part of the active workbook, but when minimised the focus doesnt return to the menu userform which disappears with the minimised worksheet and doesnt return. Cant call userform again because it it is populated by a activate macro.

    I just need the menu userform to show again.

    Workbook attached... selct incident file...select view databse and youll see what I mean

    Any ideas appreciated
    Attached Files Attached Files
    Last edited by nigelog; 07-07-2017 at 06:32 AM.

  2. #2
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    I just need the menu userform to show again.
    what is the name of this form in your file
    When clicking View Database must the form be hidden so that you can view the database
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

  3. #3
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    The secondary user form is F06_DbViewer which does not need to be visible. A dbl_Click event fires another entry userform for updating that entry

    when finished it would be preferable to display the F01_NewMenu again - I tried a worksheet deactivate but didn't work
    Last edited by nigelog; 07-07-2017 at 08:19 AM.

  4. #4
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Please excuse me for not understanding....
    selct incident file...select view databse and youll see what I mean
    When I select incident file F10_Incident form Shows
    What must now happen when you press database

  5. #5
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Hi Sintek
    View Database opens the worksheet "Database" which contains incident entries. Row items can be edited by dbl_Click

    Its getting back from this is the problem

  6. #6
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    K so after Database press The main Form shows vbModeless...What do you want to do from there....
    Why not just close the Main form and then have a command button on data sheet to call Whateva form you want next

  7. #7
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Full database has thousands of entries, it would require a floating command button always visible even after scrolling. I could solve the problem by putting the database into a new workbook but this is the way they want it here. They see it as its a dead end if they open the database and the workbook has to be closed and re opened to do anything else.

    I even added a minimise to the main menu to get around other problems but cant find a way to keep the Main Menu minimised in a corner or something that can then be maximised.
    Last edited by nigelog; 07-07-2017 at 09:27 AM.

  8. #8
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Why not just freeze the top pane of Database and place the command button there.

  9. #9
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Haha - its already frozen so doable. Problem is if I use
    Please Login or Register  to view this content.
    the userform shows but is not populated.
    Basically when the worksheet is minimised the userform must be minimised can I use
    Please Login or Register  to view this content.

  10. #10
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Went that way Sintek... Moved code from Userform open to a module Sub called from Open and then can be called from a button macro on worksheet

    Not elegant but works lol

    Thanks for the input Sintek
    Last edited by nigelog; 07-07-2017 at 10:46 AM.

  11. #11
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Jut wish i understood the inner workings....Surely could come up with simpler method...Not to worry. if it works it works.

  12. #12
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: if worksheet called from menu userform is minimised menu userform disappears - can thi

    Hi Sintek

    The main scope of the menus is to automatically update , on opening, data that is date reliant like expiry dates. Each menu has a sub in a module which scans a predefined table for date entries relevant to that section. The labels are created dynamically using the header row , the text boxes and dates load if they qualify so the menu is self sizing depending on entries. In worksheet "data" add a date in any column or change a heading name and reopen the workbook. You'll get the gist of it. If you look at the userform in vba editor you'll see how its built

    code was given to me by GregM on here as a solution to constantly adding names to a form

+ 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] Main Menu Userform not visible unless other workbooks closed or minimised
    By nigelog in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-06-2017, 01:33 PM
  2. Drop down menu for VBA Userform
    By Cremorneguy in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-25-2015, 05:34 AM
  3. Right Click Menu on Userform
    By jason_kelly in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-30-2010, 12:11 PM
  4. [SOLVED] UserForm Popup Menu ?
    By RAFAAJ2000 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-11-2005, 01:05 PM
  5. Menu Bar:UserForm of Excel
    By Syed Haider Ali in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-19-2005, 09:09 AM
  6. Using listbox as menu on userform
    By Zarqy in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-04-2005, 10:06 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