Fange en shapes contextmenu i et visio dokument
Hvordan får jeg fat i en shapes context menu ind i et visio dokument.Microsoft.Office.Interop.Visio.Application VisioInst = new Microsoft.Office.Interop.Visio.Application();
Microsoft.Office.Interop.Visio.Documents VisioDocs = null;
Microsoft.Office.Interop.Visio.Document VisioDoc = null;
Microsoft.Office.Interop.Visio.Pages VisioPages = null;
Microsoft.Office.Interop.Visio.Page VisioPage = null;
Microsoft.Office.Interop.Visio.Shapes VisioShapes = null;
Microsoft.Office.Interop.Visio.Shape VisioShape = null;
VisioInst.Documents.Open("visiodoc.vsd");
VisioDocs = VisioInst.Documents;
VisioDoc = VisioDocs.get_ItemFromID(0);
VisioPages = VisioDoc.Pages;
VisioPage = VisioPages.get_ItemFromID(0);
VisioShapes = VisioPage.Shapes; // alle shapes
for (int i=0; i < VisioShapes.Count; i++)
{
VisioShape = VisioShapes.get_ItemFromID(i);
..
menu = VisioShape...... <- Hvad skal jeg skrive her?
..
}