S
stewart
hi everyone.
I 've been studying in automation programming for couple days.
Now i 've already known how to create a com component and how to manipulate
a word application (like open or write some words into a document)use vc++,
but i don't know how to return a word application or document object to VBA.
What i want is :
create a com automation component.name "word.control"
which has two function:
the first is : "DisableMenu(bool enable)"can disable or enable some word
menu item
and the second is :GetWordDoc()
return a IDISPATCH(??) behave that wod document to vba.
so i can use VBA to createobject("word.control")
then call the function DisableMenu()
then call the function GetWordDoc()
So the vba can simple continue control that document.
The Question is : how can i return a right IDSIPATCH to VBA?Or I should
return some other Type pointer?
Please Help me !!!i 've already stuck in this question for few weeks.
I 've been studying in automation programming for couple days.
Now i 've already known how to create a com component and how to manipulate
a word application (like open or write some words into a document)use vc++,
but i don't know how to return a word application or document object to VBA.
What i want is :
create a com automation component.name "word.control"
which has two function:
the first is : "DisableMenu(bool enable)"can disable or enable some word
menu item
and the second is :GetWordDoc()
return a IDISPATCH(??) behave that wod document to vba.
so i can use VBA to createobject("word.control")
then call the function DisableMenu()
then call the function GetWordDoc()
So the vba can simple continue control that document.
The Question is : how can i return a right IDSIPATCH to VBA?Or I should
return some other Type pointer?
Please Help me !!!i 've already stuck in this question for few weeks.