Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
how automaticly print excel sheet
Hi Jim,
Are there similar things for Word, PowerPoint, IE, and etc.? Will it work for VB .NET also? Thanks, David ---- Original Message ---- how automaticly print excel sheet. From: Jim Rech Date Posted: 12/8/2003 2:48:00 PM One way to do that is to use the Windows ShellExecute API call. This essentially does the same thing as right-clicking an XLS file in Windows Explorer and picking Print. I don't know what the dBase syntax is for making API calls (or if it's supported at all) but this is how it could be done from another app that supports VB like Word: Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _ (ByVal hwnd As Long, ByVal lpOperation As String, _ ByVal lpFile As String, ByVal lpParameters As String, _ ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long Sub LaunchXLS() ShellExecute 0, "Print", "c:\book1.xls", "", "C:\", 0 End Sub -- Jim Rech Excel MVP *** Sent via Devdex http://www.devdex.com *** Don't just participate in USENET...get rewarded for it! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Footes - Automaticly print on every print job - Excel 2007 | Excel Discussion (Misc queries) | |||
automaticly paste info from another sheet | Excel Discussion (Misc queries) | |||
Why do I get a print error light trying to print an excel sheet ? | Excel Discussion (Misc queries) | |||
How do I copy a print format from sheet to sheet in excel ? | Excel Discussion (Misc queries) | |||
how automaticly print excel sheet. | Excel Programming |