Skip to main content

[Migrated content. Thread originally posted on 28 March 2011]

Does anyone have sample code to invoke Adobe Reader 9.0?

[Migrated content. Thread originally posted on 28 March 2011]

Does anyone have sample code to invoke Adobe Reader 9.0?

What product are you using, Net Express or Visual COBOL, native code or managed code for .NET?

What is it that you wish to do with abode reader, view files, print files?

There is an ActiveX control for Reader but I believe in order to interface with it you need the Acrobat SDK.

I tried to do a quick sample here on a WinForm and when I tried to use the ActiveX control directly it was looking for a license.

[Migrated content. Thread originally posted on 28 March 2011]

Does anyone have sample code to invoke Adobe Reader 9.0?

if you are using visual cobol i.e. with .net capabilities then the following line should work.

invoke type "System.Diagnostics.Process"::"Start"("NeilW.pdf")

providing the pc as PDF files associated with the adobe reader.

i would also "wrap" that up in a try catch routine.

[Migrated content. Thread originally posted on 28 March 2011]

Does anyone have sample code to invoke Adobe Reader 9.0?

What product are you using, Net Express or Visual COBOL, native code or managed code for .NET?
Net Express 5.1

What is it that you wish to do with abode reader, view files, print files?
Need to view files and print files.

We are currently calling Adobe Reader with a simple call as follows:

move 275 to command-line-len
Call "CBL_EXEC_RUN_UNIT" using wPdfCommandLine
by value command-line-len
by reference run-unit-id
by value stack-size
flags
returning status-code
wPdfCommandLine is:
"C:\\Program Files\\Adobe\\Reader 8.0\\Reader\\AcroRd32.exe" FileName.pdf

I understand Adobe will not support such a call in later version.



[Migrated content. Thread originally posted on 28 March 2011]

Does anyone have sample code to invoke Adobe Reader 9.0?

What product are you using, Net Express or Visual COBOL, native code or managed code for .NET?
Net Express 5.1

What is it that you wish to do with abode reader, view files, print files?
Need to view files and print files.

We are currently calling Adobe Reader with a simple call as follows:

move 275 to command-line-len
Call "CBL_EXEC_RUN_UNIT" using wPdfCommandLine
by value command-line-len
by reference run-unit-id
by value stack-size
flags
returning status-code
wPdfCommandLine is:
"C:\\Program Files\\Adobe\\Reader 8.0\\Reader\\AcroRd32.exe" FileName.pdf

I understand Adobe will not support such a call in later version.



[Migrated content. Thread originally posted on 28 March 2011]

Does anyone have sample code to invoke Adobe Reader 9.0?

I am unaware of Adobe making changes so that launching it from a command line would not work.
The call to CBL_EXEC_RUN_UNIT basically just launches a new process to execute the command line that you give it.

Do you have a link to the Adobe reference that makes this claim?

Thanks.