Printing IE in VB
Printing IE in VB
Printing IE in VB
Printing IE in VB
Printing IE in VB
Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB
Printing IE in VB Printing IE in VB
Printing IE in VB
Go Back  Xtreme Visual Basic Talk > > > Printing IE in VB


Reply
 
Thread Tools Display Modes
  #1  
Old 12-18-2003, 09:14 PM
azdbacks azdbacks is offline
Newcomer
 
Join Date: Dec 2003
Location: Arizona
Posts: 2
Default Printing IE in VB


I have a web link setup to a pdf. Using VB, I can open the the link using IE. Does anyone know how to automate printing the page from VB?

Thanks for the help.

Here is the code that I have so far:


Set Explorer = New SHDocVw.InternetExplorer
Explorer.Visible = True
Explorer.Navigate "http:\\phx01.phx.com/reports/issrpts/Allcodes.pdf"

'This is where I need to be able to print the pdf

Set Explorer = Nothing

Last edited by azdbacks; 12-19-2003 at 03:01 PM.
Reply With Quote
  #2  
Old 12-21-2003, 04:21 PM
azdbacks azdbacks is offline
Newcomer
 
Join Date: Dec 2003
Location: Arizona
Posts: 2
Default

I was working in VB.net and this works.

I deleted the line:

ie.Visible = True

The focus is then put on the "Print" window, and then
"Enter" can be used. I would prefer a solution with a function,
but for now, I can settle with sendkeys.

ie = CreateObject("InternetExplorer.Application")
ie.Navigate("http://www.google.com")

System.Threading.Thread.Sleep(5000)
SendKeys.SendWait("^p")
System.Threading.Thread.Sleep(1000)
SendKeys.SendWait("{ENTER}")
System.Threading.Thread.Sleep(5000)
ie.Quit()

-azdbacks
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Printing In VB rajapandian General 3 03-15-2004 12:32 AM
Printing an Excel sheet from a VB form iceman Excel 1 08-11-2003 02:45 PM
Printing Access Report from VB JerryEng Database and Reporting 3 11-27-2002 02:57 PM
QB to VB Conversion - By AIO BillSoo Tutors' Corner 0 08-06-2002 12:37 PM
why not use flash? wild wolf Game Programming 24 01-29-2002 12:04 PM

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
Printing IE in VB
Printing IE in VB
Printing IE in VB Printing IE in VB
Printing IE in VB
Printing IE in VB
Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB Printing IE in VB
Printing IE in VB
Printing IE in VB
 
Printing IE in VB
Printing IE in VB
 
-->