none
Stealth Mode Create Visio Document from C# Desktop App RRS feed

  • Question

  • I'd like to insure that the user can't get his mouse pointer into the Visio instance while I'm creating the document. Is there a way to do this (see below) so that nothing pops up on the task bar? Having the drawing run as fast as possible is also very important.

    m_visioApp = new Visio.Application();

    Once the document has been created, I'm using this to save it:

    string docPath = System.Environment.GetFolderPath(System.Environment.SpecialFolder.MyDocuments) + @"\test\Vigilant.vsd";
     m_activeDocument.SaveAs(docPath);
    and then loading the file into the Visio viewer OCX. Is there a way to send m_activeDocument to the viewer without writing it to disk first?

    • Moved by May Wang - MSFT Wednesday, December 23, 2015 6:34 AM office development
    Tuesday, December 22, 2015 3:22 PM

Answers

  • Hi,

    >>I'd like to insure that the user can't get his mouse pointer into the Visio instance while I'm creating the document. Is there a way to do this (see below) so that nothing pops up on the task bar? <<

    This issue is because the Visio application is visible create by code by default which is a little different with other Office application.

    To reduce the affect this we can set the Application.Visible to false after we create a new Visio application. And if you want the Visio progress was not visible which started by code, you can try to submit the feedback from link below:
    Feedback for Microsoft Visio & Visio Services - UserVoice

    Regards & Fei


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Friday, December 25, 2015 2:27 AM
    Moderator

All replies

  • Hi,

    I help you move this case to office development forum for a better support. Thanks for your understanding.

    May


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Wednesday, December 23, 2015 6:35 AM
  • Hello Al,

    You need to save the file on the disk to be able to open it after in the Viewer control (ActiveX control).

    Please remember that you are free to use any Windows API functions to manage the cursor position and etc. See Windows API and .net languages for more information.

    Wednesday, December 23, 2015 8:55 AM
  • Hi,

    >>I'd like to insure that the user can't get his mouse pointer into the Visio instance while I'm creating the document. Is there a way to do this (see below) so that nothing pops up on the task bar? <<

    This issue is because the Visio application is visible create by code by default which is a little different with other Office application.

    To reduce the affect this we can set the Application.Visible to false after we create a new Visio application. And if you want the Visio progress was not visible which started by code, you can try to submit the feedback from link below:
    Feedback for Microsoft Visio & Visio Services - UserVoice

    Regards & Fei


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Friday, December 25, 2015 2:27 AM
    Moderator