+ Reply to Thread
Results 1 to 16 of 16

Showing a modeless form on top of a modal form

  1. #1
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Showing a modeless form on top of a modal form

    I have a sub that displays instruction in a modaless form to the user with a checkbox to "Don't show again". It works fine from within Worksheet_Activate. The first time the user activates that sheet the instructions pop up and the user can move around the sheet to see what the instructions apply to.

    I'm now trying to do the same with a UserForm. I want the UserForm to be visible with the Instructions hovering over the Form with the instructions in it.
    But I can't get it on top, it keeps being displayed underneath the UserForm which doesn't do any good.
    Foxguy

    Remember to mark your questions [Solved] and rate the answer(s)
    Forum Rules are Here

  2. #2
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,168

    Re: Showing a modeless form on top of a modal form

    I see in userforms a property of StartupPosition. Can you change this for the one that shows behind? It looks like you can also change the start top and width.

    Are you calling the Userform.show from the other userform?

  3. #3
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Re: Showing a modeless form on top of a modal form

    Yes, if I can't find a way to have it float on top, then I will have to place it off to the side, but I would rather not do that if I don't have to.

    I'm willing to do anything - call either one first, call one from the other. Anything that achieves what I want.

  4. #4
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,168

    Re: Showing a modeless form on top of a modal form

    In playing with two userforms I got an error message 104 which can't display a modless form over a modal form.

    How about making them both modeless?

  5. #5
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Re: Showing a modeless form on top of a modal form

    I hadn't thought of using 2 modaless forms. I'll have to think about that.

  6. #6
    Forum Expert
    Join Date
    08-27-2008
    Location
    England
    MS-Off Ver
    2010
    Posts
    2,561

    Re: Showing a modeless form on top of a modal form

    I may be missing something...

    Couldn't you hide the one form while the other is open? Or is it that the help form is to help with the other form (not the spreadsheet). If that is the case my recommendation would be judicious use of controltiptext (i.e. a different MO can still acheive the end goal).

    PS - this is quite a niche (read: really ought to be subsumed into the general forum) forum, with low traffic. Normally, post VBA-related stuff in Excel Programming and non-VBA stuff in Excel General to get the best response.
    Last edited by Cheeky Charlie; 09-04-2010 at 10:10 AM. Reason: PS
    CC


    If you feel really indebted please consider a donation to charity. My preferred charity is ActionAid but there are plenty of worthy alternatives.

  7. #7
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Re: Showing a modeless form on top of a modal form

    What I want to do is VBA.

    Yes it is to give instructions on how to use the form, and the form needs to be visible while the instructions are being read. Once the user has received the instructions, they won't want to see them again, which is why I have the "Don't show again" checkbox. Included in the menus are the means to turn the instructions back on. This is a very common approach to things in Windows. I'm just using the same approach. It works fine as long as it's instructions for a worksheet. I would just like to use the exact same approach with a form, but it looks like I may be out of luck.

  8. #8
    Forum Expert
    Join Date
    08-27-2008
    Location
    England
    MS-Off Ver
    2010
    Posts
    2,561

    Re: Showing a modeless form on top of a modal form

    That's fine, it's just:
    This is a very common approach to things in Windows
    is not the same as
    "This is the only way"
    The effect of controltiptext is also very commonly in Windows (and other OSs), achieves the same end goal (contextual help), is non-obtrusive if not needed... and doesn't require the user to switch options on/off

  9. #9
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Re: Showing a modeless form on top of a modal form

    I agree with you, but I would prefer to be as consistent as possible throughout the entire app, but it is in the back of my mind as an alternative approach.

    The single biggest issue I have with tooltips is that they don't say "Start Here". The user has to look at each field and then put it all together to figure out where to start. This user already believes that he knows what the end result will look like, so has preconceived ideas about what to do. Tooltips don't really deal with that, but a set of instructions hovering over the form would.

  10. #10
    Forum Expert
    Join Date
    08-27-2008
    Location
    England
    MS-Off Ver
    2010
    Posts
    2,561

    Re: Showing a modeless form on top of a modal form

    All good points, but you appear to be stuck between your ideal and practical reality, how about another tangent?:
    You could have two versions of your main userform - one with loads of contextual help, one without, which one shows can be set by your user preference toggle.

    The best solutions are always outside the box...

  11. #11
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Re: Showing a modeless form on top of a modal form

    Quote Originally Posted by Cheeky Charlie View Post
    you appear to be stuck between your ideal and practical reality
    I disagree. That's why I come here - to see if someone can give me a better solution than the one I think of myself. Hopefully I find a method that lets me keep my ideal, but usually not.

    An idea that occurred to me while I was running an errand, is to make my userform expand to fit the instructions inside it, with a checkbox to quit showing the instructions which would shrink the form. Still not my ideal, but I think it's closer than the other ideas (at least until I try to implement it).

  12. #12
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Showing a modeless form on top of a modal form

    I think you'll find that the Windows standard is to create an actual help file, not a form over a form.
    As an aside, if your user can't even work out where to start without instructions, then your form design needs rethinking.
    Remember what the dormouse said
    Feed your head

  13. #13
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Re: Showing a modeless form on top of a modal form

    I guess I phrased that wrong. It's not that he needs instructions on where to "start". That was just easier to say, rather than try to explain the actual situation. He has a predetermined idea of how things will work. I imagine most programmers have the same problem with clients. This particular situation is different than all my other clients. I have told him upfront that I didn't understand his goal, and he's not able to explain it to me so that I feel confident that I understand. I can't figure out what questions to ask to get the kind of answers I need (possibly because of a language issue - as they say England and America are separated by a common language), so I have to trust him that he knows what he needs. So every time he sees something new he assumes that he already knows how it will work, and I feel it necessary to give him "instructions" on how to get to his goal. I may not understand the goal, but I understand how to get to it. So far, he as agreed that everything I have come up with is better than what he thought he needed, but I can't count on that continuing.

  14. #14
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436

    Re: Showing a modeless form on top of a modal form

    I sometimes use the approach similar to the Find dialog used on a worksheet.
    Where it has a button for the Options which increases the height of the dialog to reveal more detail.
    Cheers
    Andy
    www.andypope.info

  15. #15
    Forum Expert
    Join Date
    08-27-2008
    Location
    England
    MS-Off Ver
    2010
    Posts
    2,561

    Re: Showing a modeless form on top of a modal form

    If this is the issue:
    This user already believes that he knows what the end result will look like, so has preconceived ideas about what to do.
    You could prepopulate the form with an example (best in conjunction with selecting the text of each box on entry)

  16. #16
    Forum Expert
    Join Date
    03-31-2009
    Location
    Barstow, Ca
    MS-Off Ver
    Excel 2002 & 2007
    Posts
    2,164

    Re: Showing a modeless form on top of a modal form

    Andy;

    That is the approach I think I'm going to use. Unless I hear from someone else that has a different approach that I like better.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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