.NET

Reply
Mentor
matus.brlit
Posts: 244
Registered: ‎03-11-2008
Message 1 of 3 (342 Views)

Access drawing from new thread

342 Views, 2 Replies
02-17-2012 12:07 AM

Hi,

 

I found out, that you can't read AcApp.DocumentManager.MdiActiveDocument from a new thread, so I was passing the reference to the document to every method that needed to use it

But then I found out, that HostApplicationServices.WorkingDatabase allows me to access the database from a new thread.

So I'm wondering, is there any other difference, whether I access the database using AcApp.DocumentManager.MdiActiveDocument.Database or HostApplicationServices.WorkingDatabase ?

 

And is there some way for thread-sefe access to the active document?