Board index » delphi » MS Word 97, Delphi3 & DDE

MS Word 97, Delphi3 & DDE

Hi ,

Is it possible to start Word97 VBA commands by using the DDEexecuteMacro
method from the DDEservConv component ? In Word 7.0 it was, but now if I
try to do that in Word 8.0, a TmpDDE-macro is created but in a wrong
Syntax.

Delphi Code:
.
.
.
ExecuteMacro (Pchar ([my VBA Command e.g. Selection.Insert
(Type:=7)]),false) .......
.
.

Word97 creates TmpDDE-macro:

Dim Type_
.
.
Wordbasic.call "Selection.Insert...." , Type_ = 7
.
.

and thats of course the wrong Syntax

Thanks for help

 

Re:MS Word 97, Delphi3 & DDE


Frank,

Why are you using DDE ?
It is much better to use OLE. Like

vWord := CreateObject('WordBASIC');

then you can use whichever routines you need.

Word 97 has a *very* different external interface then previous versions, so
check the VBAWRD8.HLP file in the office directory.

Richard....
    Frank wrote in message <3575AAB9.DCFB4...@cityweb.de>...
    Hi ,
    Is it possible to start Word97 VBA commands by using the DDEexecuteMacro
method from the DDEservConv component ? In Word 7.0 it was, but now if I try
to do that in Word 8.0, a TmpDDE-macro is created but in a wrong Syntax.

    Delphi Code:
    .
    .
    .
    ExecuteMacro (Pchar ([my VBA Command e.g. Selection.Insert
(Type:=7)]),false) .......
    .
    .

    Word97 creates TmpDDE-macro:

    Dim Type_
    .
    .
    Wordbasic.call "Selection.Insert...." , Type_ = 7
    .
    .

    and thats of course the wrong Syntax

    Thanks for help

Other Threads