problem : adding custom task pane in IaddinUtilities

R

RAKI

Hi all,

Here am working with word 2007 addin.
Environment : office 2007, VSTO SE

Funtionality : Client will access the IAddinUtilities interface which is
declared in com addin. the interface has a method called
setWordMetaData(document ID,document Type). The method will fetch the data
from webservices using documentID and depending on the documentType it will
show correct custom task panel. (client code)

word.Document document = application.ActiveDocument;
object addinName = "SampleAddin";
core.COMAddIn comadin = application.COMAddIns.Item(ref addinName);
utils = (SampleAddin.IAddinUtilities)comadin.Object;
utils.SetWordMeataData("1234","DD");

Problem : the problem what am facing is. Depending on the document type am
writing to show custom task panel like this in com addin

if (metaDataString.Equals("DD"))
{
ThisAddIn.ctp1.Visible = true;
ThisAddIn.ctp1.Width = 300;
}
ctp1 is declared as static custom task pane object in ThisAddin class

when i run the application i can see the custom task pane which is empty.

but the custom task pane which i developed should read the active document
content controls and should build a tree view.

Does anybody know how can i get hold of custom task pane in IaddinUtilities
and reload the Usercontrol attached to that custom task pane so that i can
see the treeview loaded with nodes.

Its confuse i know but can ask questions if u dont understand.
please i need ur help
thanks in advance
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top