Login
`
Templates, Tools and Utilities
|
||
Add a comment to an Icetips ArticlePlease add your comments to this article.
Please note that you must provide both a name and a valid email address in order
for us to publish your comment. Comments are moderated and are not visible until they have been approved. Spam is never approved!
Back to article list Search Articles Add Comment Printer friendly Direct link Par2: MS Word from Clarion with DDE 2000-03-16 -- Oddmar Dam MS Word with DDE
How to use MS Word in Clarion, using DDE
! Include DDE.CLW Inside the Local MAP
! FileName = CSTRING(128)
! Channel = LONG
FileName = 'test.DOC'
RUN('winword /a',0)
IF RUNCODE() <> 0
MESSAGE(ERROR() & ' Error Code ' & RunCode())
.
DISPLAY()
Channel = DDECLIENT('WinWord')
LOOP UNTIL Channel <> 0
Channel = DDECLIENT('WinWord')
X# += 1
IF X# = 100 ! Timeout
MESSAGE('Word did not start')
BREAK
.
.
IF Channel <> 0
IF EXISTS(FileName)
DDEEXECUTE(Channel,'[FileOpen("' & FileName & '")]')
ELSE
DDEEXECUTE(Channel,'[FileSaveAs "' & FileName & '"]')
.
.
DISPLAY
Today is November 23, 2024, 2:10 am This article has been viewed 35228 times.
|
|