Hi,
I have some problem, I can't find another sintaks to create openoffice writer from
openedge 10.2a. All samples just like this :
DEFINE VARIABLE hSM AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE hDesktop AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE hDocument AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE hText AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE hCursor AS COM-HANDLE NO-UNDO.
/* Some methods require an Array parameters for extra arguments. The
only Progress database that translates to Array is RAW. */
DEFINE VARIABLE extraArgs AS RAW NO-UNDO.
CREATE "com.sun.star.ServiceManager" hSM.
hDesktop = hSM:createInstance("com.sun.star.frame.Desktop").
hDocument = hDesktop:loadComponentFromURL("private:factory/swriter", "_blank", 0, extraArgs).
hText = hDocument:getText().
hCursor = hText:createTextCursor().
hText:insertString(hCursor, "This is an example document.", FALSE).
I need more sintaks like how to down 1 line or direct save into file without popup.
Can anybody in this room help me. Tq for your help and attention.
Frankk
Googling... :)
Hi,
Infact I did not work writer until now. I used Calc many times...
I think you need to check like belowed page.
https://wiki.openoffice.org/wiki/Documentation/BASIC_Guide/StarDesktop
https://wiki.openoffice.org/wiki/Saving_a_document
You may see many usage over there.
Regards,
Mucip:)