<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Detect if a drawing was OPENED? in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913368#M78619</link>
    <description>Hi, there!&lt;BR /&gt;
&lt;BR /&gt;
I have a specific problem regarding the DocumentCreated reactor, that is, I need to distinguish between a drawing being NEWLY CREATED or OPENED. Is there any indication for either case?&lt;BR /&gt;
After a lot of trying and searching, I'm quite desparate by now &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Is there a sensible way for accomplishing this using DocumentCreated? Did I overlook any possibilities?&lt;BR /&gt;
&lt;BR /&gt;
Thanks for any help!&lt;BR /&gt;
Greetings,&lt;BR /&gt;
AlfredG</description>
    <pubDate>Tue, 13 Mar 2007 15:55:11 GMT</pubDate>
    <dc:creator>rmduser</dc:creator>
    <dc:date>2007-03-13T15:55:11Z</dc:date>
    <item>
      <title>Detect if a drawing was OPENED?</title>
      <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913368#M78619</link>
      <description>Hi, there!&lt;BR /&gt;
&lt;BR /&gt;
I have a specific problem regarding the DocumentCreated reactor, that is, I need to distinguish between a drawing being NEWLY CREATED or OPENED. Is there any indication for either case?&lt;BR /&gt;
After a lot of trying and searching, I'm quite desparate by now &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Is there a sensible way for accomplishing this using DocumentCreated? Did I overlook any possibilities?&lt;BR /&gt;
&lt;BR /&gt;
Thanks for any help!&lt;BR /&gt;
Greetings,&lt;BR /&gt;
AlfredG</description>
      <pubDate>Tue, 13 Mar 2007 15:55:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913368#M78619</guid>
      <dc:creator>rmduser</dc:creator>
      <dc:date>2007-03-13T15:55:11Z</dc:date>
    </item>
    <item>
      <title>Re: Detect if a drawing was OPENED?</title>
      <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913369#M78620</link>
      <description>I know if lisp we would look at the system variable 'dwgtitled'.  If it&lt;BR /&gt;
returned 0, then it is a new drawing.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
&lt;BR /&gt;
Tim&lt;BR /&gt;
"A blind man lets nothing block his vision."&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;ALFREDG&gt; wrote in message news:5516699@discussion.autodesk.com...&lt;BR /&gt;
Hi, there!&lt;BR /&gt;
&lt;BR /&gt;
I have a specific problem regarding the DocumentCreated reactor, that is, I&lt;BR /&gt;
need to distinguish between a drawing being NEWLY CREATED or OPENED. Is&lt;BR /&gt;
there any indication for either case?&lt;BR /&gt;
After a lot of trying and searching, I'm quite desparate by now &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Is there a sensible way for accomplishing this using DocumentCreated? Did I&lt;BR /&gt;
overlook any possibilities?&lt;BR /&gt;
&lt;BR /&gt;
Thanks for any help!&lt;BR /&gt;
Greetings,&lt;BR /&gt;
AlfredG&lt;/ALFREDG&gt;</description>
      <pubDate>Tue, 13 Mar 2007 16:25:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913369#M78620</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-13T16:25:49Z</dc:date>
    </item>
    <item>
      <title>Re: Detect if a drawing was OPENED?</title>
      <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913370#M78621</link>
      <description>If the OriginalFilename property of the Database&lt;BR /&gt;
ends with .DWT or is an empty string, that should&lt;BR /&gt;
indicate it is a new document.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
http://www.caddzone.com&lt;BR /&gt;
&lt;BR /&gt;
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007&lt;BR /&gt;
http://www.acadxtabs.com&lt;BR /&gt;
&lt;BR /&gt;
&lt;ALFREDG&gt; wrote in message news:5516699@discussion.autodesk.com...&lt;BR /&gt;
Hi, there!&lt;BR /&gt;
&lt;BR /&gt;
I have a specific problem regarding the DocumentCreated reactor, that is, I need to distinguish between a drawing being NEWLY CREATED or OPENED. Is there any indication for either case?&lt;BR /&gt;
After a lot of trying and searching, I'm quite desparate by now &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Is there a sensible way for accomplishing this using DocumentCreated? Did I overlook any possibilities?&lt;BR /&gt;
&lt;BR /&gt;
Thanks for any help!&lt;BR /&gt;
Greetings,&lt;BR /&gt;
AlfredG&lt;/ALFREDG&gt;</description>
      <pubDate>Tue, 13 Mar 2007 16:41:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913370#M78621</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-13T16:41:12Z</dc:date>
    </item>
    <item>
      <title>Re: Detect if a drawing was OPENED?</title>
      <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913371#M78622</link>
      <description>You can use a dwg as a template, can not assume the ending to be "dwt" for &lt;BR /&gt;
new drawings.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
/Matt&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
"Tony Tanzillo" &lt;TONY.TANZILLO&gt; wrote in message &lt;BR /&gt;
news:5516776@discussion.autodesk.com...&lt;BR /&gt;
If the OriginalFilename property of the Database&lt;BR /&gt;
ends with .DWT or is an empty string, that should&lt;BR /&gt;
indicate it is a new document.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
http://www.caddzone.com&lt;BR /&gt;
&lt;BR /&gt;
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007&lt;BR /&gt;
http://www.acadxtabs.com&lt;BR /&gt;
&lt;BR /&gt;
&lt;ALFREDG&gt; wrote in message news:5516699@discussion.autodesk.com...&lt;BR /&gt;
Hi, there!&lt;BR /&gt;
&lt;BR /&gt;
I have a specific problem regarding the DocumentCreated reactor, that is, I &lt;BR /&gt;
need to distinguish between a drawing being NEWLY CREATED or OPENED. Is &lt;BR /&gt;
there any indication for either case?&lt;BR /&gt;
After a lot of trying and searching, I'm quite desparate by now &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Is there a sensible way for accomplishing this using DocumentCreated? Did I &lt;BR /&gt;
overlook any possibilities?&lt;BR /&gt;
&lt;BR /&gt;
Thanks for any help!&lt;BR /&gt;
Greetings,&lt;BR /&gt;
AlfredG&lt;/ALFREDG&gt;&lt;/TONY.TANZILLO&gt;</description>
      <pubDate>Wed, 14 Mar 2007 06:40:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913371#M78622</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-14T06:40:50Z</dc:date>
    </item>
    <item>
      <title>Re: Detect if a drawing was OPENED?</title>
      <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913372#M78623</link>
      <description>Yea, but that doesn't matter if you use&lt;BR /&gt;
this (even simpler) test:&lt;BR /&gt;
&lt;BR /&gt;
bool IsNewDrawing(Document doc)&lt;BR /&gt;
{&lt;BR /&gt;
    return doc.Name == doc.Database.Filename;&lt;BR /&gt;
}&lt;BR /&gt;
&lt;BR /&gt;
Only in a new, unsaved drawing should these&lt;BR /&gt;
two properties have different values.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
http://www.caddzone.com&lt;BR /&gt;
&lt;BR /&gt;
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007&lt;BR /&gt;
http://www.acadxtabs.com&lt;BR /&gt;
&lt;BR /&gt;
"Matt" &lt;NOSPAM&gt; wrote in message news:5517603@discussion.autodesk.com...&lt;BR /&gt;
You can use a dwg as a template, can not assume the ending to be "dwt" for &lt;BR /&gt;
new drawings.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
/Matt&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
"Tony Tanzillo" &lt;TONY.TANZILLO&gt; wrote in message &lt;BR /&gt;
news:5516776@discussion.autodesk.com...&lt;BR /&gt;
If the OriginalFilename property of the Database&lt;BR /&gt;
ends with .DWT or is an empty string, that should&lt;BR /&gt;
indicate it is a new document.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
http://www.caddzone.com&lt;BR /&gt;
&lt;BR /&gt;
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007&lt;BR /&gt;
http://www.acadxtabs.com&lt;BR /&gt;
&lt;BR /&gt;
&lt;ALFREDG&gt; wrote in message news:5516699@discussion.autodesk.com...&lt;BR /&gt;
Hi, there!&lt;BR /&gt;
&lt;BR /&gt;
I have a specific problem regarding the DocumentCreated reactor, that is, I &lt;BR /&gt;
need to distinguish between a drawing being NEWLY CREATED or OPENED. Is &lt;BR /&gt;
there any indication for either case?&lt;BR /&gt;
After a lot of trying and searching, I'm quite desparate by now &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Is there a sensible way for accomplishing this using DocumentCreated? Did I &lt;BR /&gt;
overlook any possibilities?&lt;BR /&gt;
&lt;BR /&gt;
Thanks for any help!&lt;BR /&gt;
Greetings,&lt;BR /&gt;
AlfredG&lt;/ALFREDG&gt;&lt;/TONY.TANZILLO&gt;&lt;/NOSPAM&gt;</description>
      <pubDate>Wed, 14 Mar 2007 08:41:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913372#M78623</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-14T08:41:52Z</dc:date>
    </item>
    <item>
      <title>Re: Detect if a drawing was OPENED?</title>
      <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913373#M78624</link>
      <description>Pretty cool: I was just thinking about the problem and came up with a similar idea myself, just seconds before getting notified about your last reply. In my case, I was trying to compare the "FileName" and "OriginalFileName" properties of the Database, which would NOT work.&lt;BR /&gt;
&lt;BR /&gt;
However, YOUR suggestion seems to do the job!&lt;BR /&gt;
Thanks a lot, you really saved my day! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Cheers,&lt;BR /&gt;
Al</description>
      <pubDate>Wed, 14 Mar 2007 08:53:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913373#M78624</guid>
      <dc:creator>rmduser</dc:creator>
      <dc:date>2007-03-14T08:53:57Z</dc:date>
    </item>
    <item>
      <title>Re: Detect if a drawing was OPENED?</title>
      <link>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913374#M78625</link>
      <description>Oops, the == should be !=&lt;BR /&gt;
&lt;BR /&gt;
public bool IsNewDrawing(Document doc)&lt;BR /&gt;
{&lt;BR /&gt;
    return doc.Name != doc.Database.Filename;&lt;BR /&gt;
}&lt;BR /&gt;
&lt;BR /&gt;
- &lt;BR /&gt;
http://www.caddzone.com&lt;BR /&gt;
&lt;BR /&gt;
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007&lt;BR /&gt;
http://www.acadxtabs.com&lt;BR /&gt;
&lt;BR /&gt;
"Tony Tanzillo" &lt;TONY.TANZILLO&gt; wrote in message news:5517635@discussion.autodesk.com...&lt;BR /&gt;
Yea, but that doesn't matter if you use&lt;BR /&gt;
this (even simpler) test:&lt;BR /&gt;
&lt;BR /&gt;
bool IsNewDrawing(Document doc)&lt;BR /&gt;
{&lt;BR /&gt;
    return doc.Name == doc.Database.Filename;&lt;BR /&gt;
}&lt;BR /&gt;
&lt;BR /&gt;
Only in a new, unsaved drawing should these&lt;BR /&gt;
two properties have different values.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
http://www.caddzone.com&lt;BR /&gt;
&lt;BR /&gt;
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007&lt;BR /&gt;
http://www.acadxtabs.com&lt;BR /&gt;
&lt;BR /&gt;
"Matt" &lt;NOSPAM&gt; wrote in message news:5517603@discussion.autodesk.com...&lt;BR /&gt;
You can use a dwg as a template, can not assume the ending to be "dwt" for &lt;BR /&gt;
new drawings.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
/Matt&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
"Tony Tanzillo" &lt;TONY.TANZILLO&gt; wrote in message &lt;BR /&gt;
news:5516776@discussion.autodesk.com...&lt;BR /&gt;
If the OriginalFilename property of the Database&lt;BR /&gt;
ends with .DWT or is an empty string, that should&lt;BR /&gt;
indicate it is a new document.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
http://www.caddzone.com&lt;BR /&gt;
&lt;BR /&gt;
AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007&lt;BR /&gt;
http://www.acadxtabs.com&lt;BR /&gt;
&lt;BR /&gt;
&lt;ALFREDG&gt; wrote in message news:5516699@discussion.autodesk.com...&lt;BR /&gt;
Hi, there!&lt;BR /&gt;
&lt;BR /&gt;
I have a specific problem regarding the DocumentCreated reactor, that is, I &lt;BR /&gt;
need to distinguish between a drawing being NEWLY CREATED or OPENED. Is &lt;BR /&gt;
there any indication for either case?&lt;BR /&gt;
After a lot of trying and searching, I'm quite desparate by now &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;
&lt;BR /&gt;
Is there a sensible way for accomplishing this using DocumentCreated? Did I &lt;BR /&gt;
overlook any possibilities?&lt;BR /&gt;
&lt;BR /&gt;
Thanks for any help!&lt;BR /&gt;
Greetings,&lt;BR /&gt;
AlfredG&lt;/ALFREDG&gt;&lt;/TONY.TANZILLO&gt;&lt;/NOSPAM&gt;&lt;/TONY.TANZILLO&gt;</description>
      <pubDate>Wed, 14 Mar 2007 11:50:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/detect-if-a-drawing-was-opened/m-p/1913374#M78625</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-03-14T11:50:18Z</dc:date>
    </item>
  </channel>
</rss>

