>> newDoc.LockDocument();
The result of LockDocument() must be
Disposed() of explicitly, because that is
what unlocks the document.
If you let the runtime do it (e.g., whenever
it gets around to it), the document remains
locked until that happens.
So,
using( DocumentLock myLock = newDoc.LockDocument() )
{
// work with locked document here
} // document is unlocked here
--
http://www.caddzone.com
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007
http://www.acadxtabs.com
"Paul Richardson"
wrote in message news:5499364@discussion.autodesk.com...
CommandFlags.Session -> makes the command available in the application
context
instead of just the calling doc.
newDoc.LockDocument ->Before you edit a doc you must lock it. When an app
runs
in the doc context the doc is locked for you. Others must be locked
manually.
Attached is a sample of a test. Keyword test!
wrote in message news:5499346@discussion.autodesk.com...
Thank you,Palul.
What I can clear. ---> Adding commandFlags.Session,
newDoc is activated to the current drawing.
What I can get. --->I don't know what change was made with using
method of newDoc.LockDocument.