i've created a COM addin for several office applications
(word,excel,ppt) and have put a commandbarbutton into
each. Clicking this button calls a form. This form acts
as a user interface to the current documents document
properties so that the user only need click onto
menuitems in several context menu boxes, selected a
couple of keywords and they are set as properties
(builtin and custom) for that document. The only problem
is that I keep getting an object reference not set. I
just don't know how to pass the document type detected in
the com addin e.g.
if typeof (application) is word.application then
dim docType as word.document
wordApp = CType(application, word.application)
excelApp = nothing
pptApp = nothing
else if ...
to the form! The form uses oCustomProperties =
docType.BuiltInDocumentProperties
etc to get anything usefule done so the addin needs to
pass the docType to the form ByVal. I just don't know how
to do this. Please help!
Eternally indebted,
neuralSea
|