Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Opening Printers Container from VB app

Posted on 2003-11-09
3
Medium Priority
?
184 Views
Last Modified: 2010-05-01
I wrote a VB app that does all kinds of stuff.

I want to add an option to click on a button and have the printers container (from control panel) open up, preferable in the same window.

How can this be done?
0
Comment
Question by:visitmeoo
[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 17

Accepted Solution

by:
zzzzzooc earned 400 total points
ID: 9709542
The below works in XP. I'm not sure about other OS'.

Private Sub Form_Load()
    Call Shell("control.exe printers", vbMaximizedFocus)
End Sub
0
 
LVL 17

Expert Comment

by:zzzzzooc
ID: 9709548
This may work in Win9x:

Private Sub Form_Load()
    Call Shell("rundll32.exe shell32.dll,Control_RunDLL main.cpl @2", vbMaximizedFocus)
End Sub
0
 

Author Comment

by:visitmeoo
ID: 9709794
The solution that I accepted works in W2K.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
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.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
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…
Suggested Courses

604 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