Results 1 to 13 of 13

Thread: .Show vbModal Doesn't Show in Taskbar

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2005
    Posts
    400

    .Show vbModal Doesn't Show in Taskbar

    How come when I use ".Show vbModal", it doesn't show that form in the taskbar? When I minimize that window, both windows minimize which is what I want but I can't restore that window by clicking on the taskbar because it's not there.

  2. #2

  3. #3
    PowerPoster RhinoBull's Avatar
    Join Date
    Mar 2004
    Location
    New Amsterdam
    Posts
    24,132

    Re: .Show vbModal Doesn't Show in Taskbar

    Point of modal windows is bring user's attention to something very important.
    Execution stops until form is released (or closed if you will) so ... what else do you need ???????
    You can minimize modal window but icon appears right above taskbar (if it is at the bottom) but rest of your application will not be accessible until you close modal form...

  4. #4

  5. #5
    PowerPoster gavio's Avatar
    Join Date
    Feb 2006
    Location
    GMT+1
    Posts
    4,462

    Re: .Show vbModal Doesn't Show in Taskbar

    Quote Originally Posted by RhinoBull
    That shouldn't matter for modal forms.
    You're probobally right.

    Also, you can try to .Show it normaly, but when loaded disable the parent form and vice-versa when unloaded.

  6. #6
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: .Show vbModal Doesn't Show in Taskbar

    Modal forms are like dialog windows. They will not show in the taskbar no matter the ShowInTaskbar property setting. Because they are modal you would not have them open and switching forms in your app so no need to show the form in the taskbar.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  7. #7

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2005
    Posts
    400

    Re: .Show vbModal Doesn't Show in Taskbar

    I just want the main form to minmize, also when the opened form is minmized. I also want to be able to see it in the taskbar. Basically, all I really want is just to do something exactly like ".Show vbModal", except I can see the form in the taskbar.

  8. #8

  9. #9

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2005
    Posts
    400

    Re: .Show vbModal Doesn't Show in Taskbar

    But how would I do it?

  10. #10
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: .Show vbModal Doesn't Show in Taskbar

    If a modal form is minimized it will automatically minimize its parent form. To minimize a parent form while showing a modal form can not be done. You could do a Form1.Hide and then Form2.Show vbModal but then Form1 wont be shown in the taskbar.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  11. #11
    PowerPoster RhinoBull's Avatar
    Join Date
    Mar 2004
    Location
    New Amsterdam
    Posts
    24,132

    Re: .Show vbModal Doesn't Show in Taskbar

    MInimizing modal can create nothing but frustration to the end user - I can asure you of that. People can see forms but cannot use them and they can't find that modal screen (dialog or message box if you will because that's what modal really is) so eventually they get annoyed with all of the above and at some point they will no longer use your software. I've seen it happened.
    So, having said that I would recommend to drop this idea...

  12. #12
    Addicted Member
    Join Date
    Mar 2006
    Posts
    159

    Re: .Show vbModal Doesn't Show in Taskbar

    I don't want to flare up the debate, but I too am interested in having a form opened using vbModal show it's icon. (My modal form is a custom webbrowser, so it's not a small window or a dialogue box.)

    Mine does but not immedietly.

    Initially, when my application opens the modal form, there is no new icon showing in the taskbar. But if I click somewhere on my desktop (away from my application's 2 windows) or on another application's window and then click back on my modal form, the icon for the modal form shows up.

    How can I make it show without the delay?


    Cheers,
    Nap

  13. #13
    PowerPoster gavio's Avatar
    Join Date
    Feb 2006
    Location
    GMT+1
    Posts
    4,462

    Re: .Show vbModal Doesn't Show in Taskbar

    Put this code into the second Form (the one that should be modal):
    Code:
    Private Sub Form_Load()
        Form1.Enabled = False
    End Sub
    
    Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
        Form1.Enabled = True
    End Sub
    Then show it normally - Form2.Show.

Posting Permissions

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



Click Here to Expand Forum to Full Width