Solved

Getting VBA program on taskbar

Posted on 2001-06-18
3
296 Views
Last Modified: 2012-03-24
Ok...Another tough one...at least for me...

I have a program with several forms that is used to automate a word document.  I would like to have the forms show up on the windows taskbar (for a variety of reasons) while the program is running, if the form is "visable".

Now, I understand that with a single form program, if I check the block in the properties window ("showintaskbar") that the form will show...but this seems to only work with programs of only one form.

In my case, I have most of my code in a module called "subMain." I start the program with subMain and I use the following code

Sub Main()
Dim oform As Form1
Set oform = New Form1
    oform.Show vbModal
Set oform = Nothing
End Sub


And Form1 starts the show.  But even though I indicate in the properties section to "showintaskbar=true", for all of my forms, I can not get them to display.

Have tried a bit of troubleshooting...placed all my code in Form1 and launched, and managed to get Form1 to show up on the taskbar, but still none of the other, subsequent forms (not to mention errors associated with attempts to access variables.

Is there something I'm missing here to get all my forms on the taskbar.

thanks!

Philip





Philip

0
Comment
Question by:philipsimmons
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Expert Comment

by:agriggs
ID: 6202553
A form that is shown modally cannot be shown in the taskbar.

0
 

Author Comment

by:philipsimmons
ID: 6203074
Drat!  Any way around this...Is it possible for some forms to be modal and other not?

thanks man
0
 
LVL 2

Accepted Solution

by:
agriggs earned 100 total points
ID: 6203241
The main problem for me when I show forms non-modally is that the Show is non-blocking, i.e.


Form1.Show vbModal

does not return until the form is through, so it's easy to keep track of the instance of form1.


Form1.Show

returns immediately as soon as the form is loaded and shown.  So the code example as you gave above wouldn't work
because you unload the form when the Show returns.

Outside of this problem, you can show all of your forms non-modally.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses
Course of the Month3 days, 23 hours left to enroll

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question