Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > VB Script

Vista - Display .pdf Form

Reply
 
Old 03-28-2009   #1 (permalink)
Len


 
 

Display .pdf Form

Sorry guys, never did this one before.

I have created a button on a page which works fine. When I click on it the
form comes up with a blank page.

I want to display a form to print on a printer for school teachers to join
an association. The form is called JoinGca.pdf

My Script:

<IMG SRC="../../../Guidance/JoinGca.pdf" NAME="FormG" ALIGN=BOTTOM Border=0>

I tried other tags but I tried IMG as the last resource.

What am I doing wrong?

Thanks in Advance

Len



My System SpecsSystem Spec
Old 03-28-2009   #2 (permalink)
James Whitlow


 
 

Re: Display .pdf Form

"Len" <Len@xxxxxx> wrote in message
news:F01CD0A1-EAA3-4CE4-B07A-3D22C996A672@xxxxxx
Quote:

> Sorry guys, never did this one before.
>
> I have created a button on a page which works fine. When I click on it
> the
> form comes up with a blank page.
>
> I want to display a form to print on a printer for school teachers to join
> an association. The form is called JoinGca.pdf
If I understand what you are wanting to do, you can simply navigate to the
file. Try the below sample and see if it is along the lines of what you are
trying to do. Make sure to correct the path to the file on line 20.

Set oIE = WScript.CreateObject("InternetExplorer.Application", "IE_")
oIE.toolbar = False
oIE.statusbar = False
oIE.navigate "about:blank"

Do Until oIE.readyState = 4
WScript.Sleep 100
Loop

oIE.document.body.innerHTML = "<button id='ShowPDF'>" _
& "Show the PDF</button>"
oIE.document.all.ShowPDF.onClick = GetRef("ShowPDF")
oIE.visible = True
bLoop = True

Do
WScript.Sleep 100
Loop While bLoop

oIE.navigate "file:///c:/Guidance/JoinGca.pdf"

Sub ShowPDF
bLoop = False
End Sub

Sub IE_onQuit
WScript.Quit
End Sub


My System SpecsSystem Spec
Old 03-28-2009   #3 (permalink)
Len


 
 

Re: Display .pdf Form

James;

Still having trouble

When I hit this line:

<%Set oIE = WScript.CreateObject("InternetExplorer.Application", "IE_")

I get an Object Required Message.

any idea why?

Thanks Len

"James Whitlow" wrote:
Quote:

> "Len" <Len@xxxxxx> wrote in message
> news:F01CD0A1-EAA3-4CE4-B07A-3D22C996A672@xxxxxx
Quote:

> > Sorry guys, never did this one before.
> >
> > I have created a button on a page which works fine. When I click on it
> > the
> > form comes up with a blank page.
> >
> > I want to display a form to print on a printer for school teachers to join
> > an association. The form is called JoinGca.pdf
>
> If I understand what you are wanting to do, you can simply navigate to the
> file. Try the below sample and see if it is along the lines of what you are
> trying to do. Make sure to correct the path to the file on line 20.
>
> Set oIE = WScript.CreateObject("InternetExplorer.Application", "IE_")
> oIE.toolbar = False
> oIE.statusbar = False
> oIE.navigate "about:blank"
>
> Do Until oIE.readyState = 4
> WScript.Sleep 100
> Loop
>
> oIE.document.body.innerHTML = "<button id='ShowPDF'>" _
> & "Show the PDF</button>"
> oIE.document.all.ShowPDF.onClick = GetRef("ShowPDF")
> oIE.visible = True
> bLoop = True
>
> Do
> WScript.Sleep 100
> Loop While bLoop
>
> oIE.navigate "file:///c:/Guidance/JoinGca.pdf"
>
> Sub ShowPDF
> bLoop = False
> End Sub
>
> Sub IE_onQuit
> WScript.Quit
> End Sub
>
>
>
My System SpecsSystem Spec
Old 03-28-2009   #4 (permalink)
James Whitlow


 
 

Re: Display .pdf Form

"Len" <Len@xxxxxx> wrote in message
news:3C104649-E2EB-4165-8F2D-82D491156891@xxxxxx
Quote:

> James;
>
> Still having trouble
>
> When I hit this line:
>
> <%Set oIE = WScript.CreateObject("InternetExplorer.Application", "IE_")
>
> I get an Object Required Message.
>
> any idea why?
Did you save the file with a '.vbs' extension?


My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
Dynamic Form in WPF .NET General
Black display in preview display windows movie maker Vista music pictures video
Vista Business wont retain my display settings (on multiple display setup) Vista General
display wizard gone in vista nvidia display drivers Vista General
Feedback form Vista General


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46