Hi,
because of difficulties displaying word document in the Xbase++ dialog I made a small function to convert and display as a pdf version of the original file.
Have fun.
Regards
Zdeno
"Zdenko Bielik" napísal v správe news:4225f2b8$1268160d$3003c@news.alaska-software.com...
Hi all,
thanks for tips, infos and experiencies.
I also did some little search on internet and I made some "workaround"
In attached example I first open MS Word document and then
- it is printed with any PDF Printer or (slowly and must be installed any
virtual pdf-driver)
- saved it as PDF or (saved file has bigger size)
- Exported to PDF (this is my current choice - fast and small)
and then showed.
Hope this maybe helps someone and finds this usefull.
TIA & Regards
Zdeno
word2pdf
-
- Posts: 147
- Joined: Thu Jan 28, 2010 9:24 am
- Location: Nitra, Slovakia
- Contact:
word2pdf
- Attachments
-
- ActiveX-Doc2Pdf-Exp.zip
- (265.15 KiB) Downloaded 1314 times
Re: word2pdf
This is interesting and may be useful, but I don't see it as something to put into eXpress++, other than as a sample program.
I use the universal web browser when I want to display a .DOC or DOCX file.
I use DCHTMLVIEWER .. NAVIGATE <cFileName>
Have you tried this?
I use the universal web browser when I want to display a .DOC or DOCX file.
I use DCHTMLVIEWER .. NAVIGATE <cFileName>
Have you tried this?
The eXpress train is coming - and it has more cars.
-
- Posts: 147
- Joined: Thu Jan 28, 2010 9:24 am
- Location: Nitra, Slovakia
- Contact:
Re: word2pdf
Hi Roger,
yes, I used that function some time ago, but with newer versions of IE(I have IE 11 on Win 8.1) are two problems now:
- message with choices Run/Save/Cancel is displayed when you want show any DOC(-X) file with this class
- and NEW window with MS Word app is ALWAYS OPENED
and I/user want it have into ONE Xbase++/eXpress++ dialog
just try run your sample WebBrow.prg from \exp19\samples\activex and open any DOC file
Regards
Zdeno
yes, I used that function some time ago, but with newer versions of IE(I have IE 11 on Win 8.1) are two problems now:
- message with choices Run/Save/Cancel is displayed when you want show any DOC(-X) file with this class
- and NEW window with MS Word app is ALWAYS OPENED
and I/user want it have into ONE Xbase++/eXpress++ dialog
just try run your sample WebBrow.prg from \exp19\samples\activex and open any DOC file
Regards
Zdeno
Re: word2pdf
did your try DSOframer OCX ?Zdeno Bielik wrote:because of difficulties displaying word document in the Xbase++ dialog ...
greetings by OHR
Jimmy
Jimmy
-
- Posts: 481
- Joined: Wed Jan 27, 2010 10:25 pm
- Location: Berlin Germany
Re: word2pdf
Hello Zdeno,
thank you for sharing this.
It would be better, to open the doc as writeprotected so that the conversation can be done without a question of Word if its in use.
thank you for sharing this.
It would be better, to open the doc as writeprotected so that the conversation can be done without a question of Word if its in use.
Code: Select all
oWord:documents:open(( _cPath + _cFile ), .F., .T.)
_______________________
Best Regards
Wolfgang
Best Regards
Wolfgang
-
- Posts: 481
- Joined: Wed Jan 27, 2010 10:25 pm
- Location: Berlin Germany
Re: word2pdf
And here the same for Excel-files to PDF (in short):
Code: Select all
#define xlTypePDF 0
oExcel := CreateObject( 'Excel.Application' )
if !empty(oExcel)
oExcel:visible := .F.
oExcel:Application:DisplayAlerts:=.F.
oWorkBook:=oExcel:workbooks:open(file,,.T.)
oWorkBook:ExportAsFixedFormat(xlTypePDF,cSaveFile)
oExcel:Quit()
oExcel:Destroy()
_______________________
Best Regards
Wolfgang
Best Regards
Wolfgang