S
Scott Kurth
I have a VC++ application that opens a Visio document using COM, but I
cannot seem to prevent Visio from opening a dialog box for the user
for some of my documents. Specifically, the dialog that comes up is
as follows:
-----------------------------
Organization Chart Converter
The organization chart shapes in this drawing must be converted to
work properly in the current version of Microsoft Visio. Click Yes to
convert the shapes now. If you click No, the shapes in your drawing
will not function correctly.
-----------------------------
I would like to prevent that dialog box from being shown and have the
No button selected automatically. I have tried setting the
AlertResponse property of the Application object, but it has no
effect.
Here is a snippet of the code that I am using...
// Start Microsoft Visio and get the IVApplication object.
Visio::IVApplication app;
app.CreateDispatch("Visio.Application");
app.SetVisible(TRUE);
// Get the documents collection.
Visio::IVDocuments docs;
docs = app.GetDocuments();
// Open a Visio document.
Visio::IVDocument doc;
app.SetAlertResponse(IDNO);
doc = docs.OpenEx(strFilename, visOpenRO | visOpenMacrosDisabled |
visOpenNoWorkspace);
Does anyone have any suggestions, workarounds, or other advise?
Thanks!
Scott
cannot seem to prevent Visio from opening a dialog box for the user
for some of my documents. Specifically, the dialog that comes up is
as follows:
-----------------------------
Organization Chart Converter
The organization chart shapes in this drawing must be converted to
work properly in the current version of Microsoft Visio. Click Yes to
convert the shapes now. If you click No, the shapes in your drawing
will not function correctly.
-----------------------------
I would like to prevent that dialog box from being shown and have the
No button selected automatically. I have tried setting the
AlertResponse property of the Application object, but it has no
effect.
Here is a snippet of the code that I am using...
// Start Microsoft Visio and get the IVApplication object.
Visio::IVApplication app;
app.CreateDispatch("Visio.Application");
app.SetVisible(TRUE);
// Get the documents collection.
Visio::IVDocuments docs;
docs = app.GetDocuments();
// Open a Visio document.
Visio::IVDocument doc;
app.SetAlertResponse(IDNO);
doc = docs.OpenEx(strFilename, visOpenRO | visOpenMacrosDisabled |
visOpenNoWorkspace);
Does anyone have any suggestions, workarounds, or other advise?
Thanks!
Scott