Help using AddDocumentWindow

Help using AddDocumentWindow

Chris.Murphy
Participant Participant
952 Views
3 Replies
Message 1 of 4

Help using AddDocumentWindow

Chris.Murphy
Participant
Participant

Hello.

 

I have been experimenting with the AddDocumentWindow API to insert a custom HTML window in AutoCAD 2016. The method is super easy to use and it works great. A new document window is created and the chromium engine does a find job of handling the HTML.

 

However I am finding that AutoCAD hangs when I go to close the application after creating one of these windows. If the window is closed before exiting then everything is good but if the window is still open then it becomes a problem. 

 

Does anyone have any insight into this problem? Any possible workarounds that I might try to get around the issue? Thanks for any help. 

 

-Chris

 

 

 

[Autodesk.AutoCAD.Runtime.CommandMethod("DOCWIN")]
public void DocWin()
{
	string title = "DocWin";
	string url = "http://www.autodesk.com/";

// Don't do anything if the doc window already exists. foreach (Autodesk.AutoCAD.Windows.DocumentWindow dw in AcadApplication.DocumentWindowCollection) { if (dw.Title.Equals(title)) return; }
Autodesk.AutoCAD.Windows.DocumentWindow newdw = AcadApplication.DocumentWindowCollection.AddDocumentWindow(title, new System.Uri(url)); }

 

0 Likes
953 Views
3 Replies
Replies (3)
Message 2 of 4

moogalm
Autodesk Support
Autodesk Support

Hi Chris,

 

This behavior already reported to us, one workaroud is to turn off STARTMODE, set it to 0..

0 Likes
Message 3 of 4

Chris.Murphy
Participant
Participant

Thanks for the reply. Too bad that the AutoCAD start window has to be turned off. 

 

Is there any way to extend the start page? By this I mean add a new tab to the start page so that you could scroll from "LEARN" to "CREATE" to "MY CUSTOM TAB".

 

0 Likes
Message 4 of 4

Virupaksha_aithal
Autodesk Support
Autodesk Support

Hi chris,

 

I do not think it is possible to extend the AutoCAD default start up page at present.



Virupaksha Aithal KM
Developer Technical Services
Autodesk Developer Network

0 Likes