Word question

Word question

Postby Otto » Mon Oct 22, 2012 3:16 pm

Can someone please help me to convert this to FIVEWIN code:

ActiveDocument.SaveAs FileName:=strDocName, FileFormat:=wdFormatXMLDocument

Thanks in advance
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6332
Joined: Fri Oct 07, 2005 7:07 pm

Re: Word question

Postby ADutheil » Mon Oct 22, 2012 5:22 pm

Code: Select all  Expand view

FUNCTION TEST
LOCAL oWord := WinWordObj()
LOCAL oDoc

oDoc := oWord:Documents:Add()
#define wdFormatXMLDocument 12
oDoc:saveas( "path where you want to save\FileName", wdFormatXMLDocument )
oWord:Quit()
RETURN NIL
 


or to be closer to the way you asked:

Code: Select all  Expand view

FUNCTION TEST
LOCAL oWord := WinWordObj()
LOCAL oDoc

oWord:Documents:Add()
oDoc := oWord:ActiveDocument

 #define wdFormatXMLDocument 12
oDoc:saveas( "path where you want to save\FileName", wdFormatXMLDocument )
oWord:Quit()
RETURN NIL
 
Regards,

André Dutheil
FWH 13.04 + HB 3.2 + MSVS 10
ADutheil
 
Posts: 368
Joined: Sun May 31, 2009 6:25 pm
Location: Salvador - Bahia - Brazil

Re: Word question

Postby Otto » Mon Oct 22, 2012 5:40 pm

André,
thank you very much.
Now all is working so well.
Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6332
Joined: Fri Oct 07, 2005 7:07 pm


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 74 guests