Good afternoon,
Does anyone have a quick and dirty way to display a PDF from VFP either in a form, or natively using Adobe Reader?
Any assistance would be GREATLY appreciated...
Regards, Desmond
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html ---
Use ShellExecute()
http://leafe.com/archives/full_thread/485262
On Tue, Jul 12, 2016 at 5:04 PM, Desmond Lloyd desmond.lloyd@gmail.com wrote:
Good afternoon,
Does anyone have a quick and dirty way to display a PDF from VFP either in a form, or natively using Adobe Reader?
Any assistance would be GREATLY appreciated...
Regards, Desmond
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html
[excessive quoting removed by server]
On 2016-07-12 18:11, Ted Roche wrote:
Use ShellExecute()
Deja Vu!
Thanks to all.... Appreciate the helpe, despite my inability to locate the previous posts on this subject...
Regards, Desmond
On 12 July 2016 at 23:00, mbsoftwaresolutions@mbsoftwaresolutions.com wrote:
On 2016-07-12 18:11, Ted Roche wrote:
Use ShellExecute()
Deja Vu!
[excessive quoting removed by server]
Not to be snarky, but http://lmgtfy.com/?q=Display+PDF+in+Visual+FoxPro.
My favorite is to use ShellExecute, as Ted has already mentioned (https://www.foxite.com/archives/easy-way-to-display-pdf-file-in-vfp-form-00 00397819.htm), but the methods discussed at https://www.berezniker.com/content/pages/visual-foxpro/view-pdf-vfp-form may work better for your specific application.
Mike
-----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Desmond Lloyd Sent: Tuesday, July 12, 2016 3:05 PM To: profoxtech@leafe.com Subject: VFP Display a PDF
Good afternoon,
Does anyone have a quick and dirty way to display a PDF from VFP either in a form, or natively using Adobe Reader?
Any assistance would be GREATLY appreciated...
Regards, Desmond
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html ---
[excessive quoting removed by server]
In addition to all the answers you've got so far, I use this method:
Add the _shellexecute class from the _environ.vcx class library that ships with VFP 9 to a form
Name it 'launcher'
and run this code from the click event of a button:
Local cDocName
cDocName = GetFile('doc,xls,pdf,txt','File','Open',0,'Choose file') thisform.launcher.shellexecute (cDocName)
You can launch any file with the above extensions that you select with the getfile function
That's all there is to it
Rafael Copquin
On 12/07/2016 18:04, Desmond Lloyd wrote:
Good afternoon,
Does anyone have a quick and dirty way to display a PDF from VFP either in a form, or natively using Adobe Reader?
Any assistance would be GREATLY appreciated...
Regards, Desmond
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html
[excessive quoting removed by server]
On Tue, Jul 12, 2016 at 6:39 PM, rafael copquin rcopquin@yahoo.com.ar wrote:
In addition to all the answers you've got so far, I use this method:
Add the _shellexecute class from the _environ.vcx class library that ships with VFP 9 to a form
Name it 'launcher'
and run this code from the click event of a button:
Local cDocName
cDocName = GetFile('doc,xls,pdf,txt','File','Open',0,'Choose file') thisform.launcher.shellexecute (cDocName)
That's the best answer, the actual code. I was trolling around the archives, but couldn't locate it.
:-):-) Rafael
On 12/07/2016 20:38, Ted Roche wrote:
On Tue, Jul 12, 2016 at 6:39 PM, rafael copquin rcopquin@yahoo.com.ar wrote:
In addition to all the answers you've got so far, I use this method:
Add the _shellexecute class from the _environ.vcx class library that ships with VFP 9 to a form
Name it 'launcher'
and run this code from the click event of a button:
Local cDocName
cDocName = GetFile('doc,xls,pdf,txt','File','Open',0,'Choose file') thisform.launcher.shellexecute (cDocName)
That's the best answer, the actual code. I was trolling around the archives, but couldn't locate it.
Once again thanks for the input. Was able to get the "browser" version to work with the following exception, it opens the PDF in the reader, not the control. Accordng to the notes you should be able set an option to display the PDF in the control. I have Adobe Standard and Adobe DC Reader installed. Could not find that option in the internet options for the reader and "standard version". Did a search and Adobe says to enable the reader add on under "manager add ons" which is enabled. Still no joy...
For now am going to use the _shell execute, works just like the other. In the meantime does anyone have any suggestions on how to get the PDF to display within the control...
Thanks Again, Desmond
On 13 July 2016 at 09:28, rafael copquin rafael.copquin@gmail.com wrote:
:-):-) Rafael
On 12/07/2016 20:38, Ted Roche wrote:
On Tue, Jul 12, 2016 at 6:39 PM, rafael copquin rcopquin@yahoo.com.ar wrote:
In addition to all the answers you've got so far, I use this method:
Add the _shellexecute class from the _environ.vcx class library that ships with VFP 9 to a form
Name it 'launcher'
and run this code from the click event of a button:
Local cDocName
cDocName = GetFile('doc,xls,pdf,txt','File','Open',0,'Choose file') thisform.launcher.shellexecute (cDocName)
That's the best answer, the actual code. I was trolling around the
archives, but couldn't locate it.
[excessive quoting removed by server]
WAG here but I believe that you tell Windows the default app by file extension. I forget where that set up is today.
On Wed, Jul 13, 2016 at 11:10 AM, Desmond Lloyd desmond.lloyd@gmail.com wrote:
Once again thanks for the input. Was able to get the "browser" version to work with the following exception, it opens the PDF in the reader, not the control. Accordng to the notes you should be able set an option to display the PDF in the control. I have Adobe Standard and Adobe DC Reader installed. Could not find that option in the internet options for the reader and "standard version". Did a search and Adobe says to enable the reader add on under "manager add ons" which is enabled. Still no joy...
For now am going to use the _shell execute, works just like the other. In the meantime does anyone have any suggestions on how to get the PDF to display within the control...
Thanks Again, Desmond
On 13 July 2016 at 09:28, rafael copquin rafael.copquin@gmail.com wrote:
:-):-) Rafael
On 12/07/2016 20:38, Ted Roche wrote:
On Tue, Jul 12, 2016 at 6:39 PM, rafael copquin rcopquin@yahoo.com.ar wrote:
In addition to all the answers you've got so far, I use this method:
Add the _shellexecute class from the _environ.vcx class library that ships with VFP 9 to a form
Name it 'launcher'
and run this code from the click event of a button:
Local cDocName
cDocName = GetFile('doc,xls,pdf,txt','File','Open',0,'Choose file') thisform.launcher.shellexecute (cDocName)
That's the best answer, the actual code. I was trolling around the
archives, but couldn't locate it.
[excessive quoting removed by server]