DWGTITLED in .NET

DWGTITLED in .NET

Anonymous
Not applicable
590 Views
9 Replies
Message 1 of 10

DWGTITLED in .NET

Anonymous
Not applicable
How do i find out if the dwg has been saved from .NET? I can't find the variable DWGTITLED. Any tips?? /Mats
0 Likes
591 Views
9 Replies
Replies (9)
Message 2 of 10

Anonymous
Not applicable
Zatopek wrote: > How do i find out if the dwg has been saved from .NET? > I can't find the variable DWGTITLED. > > Any tips?? Check the FullName property or try GetVariable. -- There are 10 kinds of people: those who understand binary and those who don't.
0 Likes
Message 3 of 10

Anonymous
Not applicable
Do you mean FileName? FileName doesn't do it. It contains the name of the dwt-file before it has been saved. Where do i find GetVariable? I cannot find it on database. /M "Frank Oquendo" wrote in message news:4141b8a9$1_2@newsprd01... > Zatopek wrote: >> How do i find out if the dwg has been saved from .NET? >> I can't find the variable DWGTITLED. >> >> Any tips?? > > Check the FullName property or try GetVariable. > > -- > There are 10 kinds of people: those who understand binary and those who > don't.
0 Likes
Message 4 of 10

Anonymous
Not applicable
> FileName doesn't do it. > It contains the name of the dwt-file before it has been saved. Then that can be your test. If it is the dwt name then obviously it hasn't been saved yet. -- Mike ___________________________ Mike Tuersley CADalyst's CAD Clinic Rand IMAGINiT Technologies ___________________________ the trick is to realize that there is no spoon...
0 Likes
Message 5 of 10

Anonymous
Not applicable
But I can work in an dwt. (not likely, but i can) I just want to get the value from the dwgtitled variable. It keeps all the info i need. How do i get the value in a setvar from .net? (getvar "dwgtitled") in lisp. "Mike Tuersley" wrote in message news:1bj7qgsdabb8q$.7f29jo18kxsh.dlg@40tude.net... >> FileName doesn't do it. >> It contains the name of the dwt-file before it has been saved. > Then that can be your test. If it is the dwt name then obviously it hasn't > been saved yet. > > -- Mike > ___________________________ > Mike Tuersley > CADalyst's CAD Clinic > Rand IMAGINiT Technologies > ___________________________ > the trick is to realize that there is no spoon...
0 Likes
Message 6 of 10

Anonymous
Not applicable
"Mike Tuersley" wrote in message news:1bj7qgsdabb8q$.7f29jo18kxsh.dlg@40tude.net... >> FileName doesn't do it. >> It contains the name of the dwt-file before it has been saved. > Then that can be your test. If it is the dwt name then obviously it hasn't > been saved yet. DWGTITLED indicates if a new drawing was saved. Testing the filename doesn't work because a user can open a .DWT. He can get the Document object and from it, get the AcadDocument ActiveX object, and then use the GetVariable method. The managed wrapper API for AutoCAD is a work in progress, not done, and using it without the ActiveX API is unrealistic. FWIW, in ObjectARX, this requires accessing the MFC CDocument object for the open document, so there is likely no equivalent in the managed API. -- http://www.caddzone.com AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005 http://www.acadxtabs.com
0 Likes
Message 7 of 10

Anonymous
Not applicable
Well assuming you are using the COM interop, its just ActveDocument.GetVariable("Whatever_variable_name_you_type_here"). If that doesn't make sense, look in the help file. -- Mike ___________________________ Mike Tuersley CADalyst's CAD Clinic Rand IMAGINiT Technologies ___________________________ the trick is to realize that there is no spoon...
0 Likes
Message 8 of 10

Anonymous
Not applicable
So what you are saying is that there a no straight forward .NET method to get that variable, or any other variable. But i has to go through Active X. Have i understod you right? /M "Tony Tanzillo" wrote in message news:4141cc19_3@newsprd01... > "Mike Tuersley" wrote in message > news:1bj7qgsdabb8q$.7f29jo18kxsh.dlg@40tude.net... >>> FileName doesn't do it. >>> It contains the name of the dwt-file before it has been saved. >> Then that can be your test. If it is the dwt name then obviously it >> hasn't >> been saved yet. > > DWGTITLED indicates if a new drawing was saved. Testing > the filename doesn't work because a user can open a .DWT. > > He can get the Document object and from it, get the > AcadDocument ActiveX object, and then use the GetVariable > method. > > The managed wrapper API for AutoCAD is a work in progress, > not done, and using it without the ActiveX API is unrealistic. > > FWIW, in ObjectARX, this requires accessing the MFC > CDocument object for the open document, so there is > likely no equivalent in the managed API. > > -- > http://www.caddzone.com > > AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005 > http://www.acadxtabs.com > >
0 Likes
Message 9 of 10

Anonymous
Not applicable
Zatopek wrote: > But i has to go through Active X. That is correct. Frankly, ActiveX is far more reliable than the managed API to begin with. Even with its superior access, I've all but given up on the managed API. -- There are 10 kinds of people: those who understand binary and those who don't.
0 Likes
Message 10 of 10

Anonymous
Not applicable
In AutoCAD 2005 the .NET API won't do everything you need and you will have to use the COM API. Hopefully, we can change your mind in couple of releases. Albert "Frank Oquendo" wrote in message news:41420527$1_1@newsprd01... > Zatopek wrote: > > > But i has to go through Active X. > > That is correct. > > Frankly, ActiveX is far more reliable than the managed API to begin with. > > Even with its superior access, I've all but given up on the managed API. > > -- > There are 10 kinds of people: those who understand binary and those who > don't.
0 Likes