Community
Civil 3D Customization
Welcome to Autodesk’s AutoCAD Civil 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Civil 3D Customization topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Data Referenced Object Source drawing?

10 REPLIES 10
Reply
Message 1 of 11
Jeff_M
1369 Views, 10 Replies

Data Referenced Object Source drawing?

Is there any way to determine the source drawing of a dref'ed object? I'm not seeing anything in COM or the .NET API's, hopefully I'm just not looking in the right place.

Jeff_M, also a frequent Swamper
EESignature
10 REPLIES 10
Message 2 of 11
wang890
in reply to: Jeff_M

i wanted to do this years ago. but seems like still not available, if you can't even find it then i doubt it's there.

 

maybe use some hacking method.

Stantec
Dell Precision 5530, Prism M320PU, C3D 14/17/19
Message 3 of 11
Partha.Sarkar
in reply to: Jeff_M

Hi Jeff,

 

It seems we don’t have any API to know the Data Referenced Object Source drawing.

We can check whether the Entity is a reference object using the following API, but there is none to know the source DWG file of the referenced entity.

 

Entity.IsReferenceObject Property

 

-> Gets whether the Entity is a reference object. A reference object is located in another drawing, and linked using a data shortcut or Vault. If the entity is native to the current drawing this property returns false; if it is being referenced via data shortcuts or AutoCAD Vault it returns true.

 

I have logged a wish list for the same in our internal system.

 

Could you give me an use case for this "Data Referenced Object Source drawing " ?

How this API will be useful for our developer community ?

 

Thanks,

Partha Sarkar



Partha Sarkar
Developer Technical Services
Autodesk Developer Network

Message 4 of 11
Jeff_M
in reply to: Partha.Sarkar

There have been a few times over the years I've tried to do something with the source drawing. I'm not recalling now what those previous reasons were. This thread was started when I was asked if I could create a command to force the sync'ing of Pipe/Structure styles of Dref'ed parts with the source drawing. This, I thought, was a great request because I often need to change parts in the source drawing which changes the style, but then I need to manually change the style of those parts in the Dref drawings.

Jeff_M, also a frequent Swamper
EESignature
Message 5 of 11
ralstogj
in reply to: Jeff_M

I have run into the same issue as Jeff with the pipe styles not in sync with the source drawing a real pain on large drawing sets. I was thinking a while back it would be cool to generate a diagram of how all drawings dref and xrefd relate to one another on one page. as you can get a real spider web of connections between drawings and different projects if working on a complex development.
Regards

Justin Ralston
http://c3dxtreme.blogspot.com/
Message 6 of 11
tyronebk
in reply to: Partha.Sarkar

Similar to what Justin mentioned, we have multi-stage projects (that likely did not start out as such) where the shortcuts become a complex web pointing everywhere. Since shortcuts sources can change depending on whether the user is pathed to the correct project, often users will be pointing to the incorrect version of objects without knowing it. Access to the source object references through the API would make quick work of confirming that the shortcuts are pointing to the correct objects, or creating a organization tree for the projects drawings.

Message 7 of 11
kbarnettza
in reply to: tyronebk

Greetings,

Has the status changed? Can we now retrieve the path of the source DWG of a data reference?

If Yes, please provide a link to the forum post or provide details.

Thank You.

Kevin.

 

Message 8 of 11
Jeff_M
in reply to: kbarnettza

No change as of C3D2017.
Jeff_M, also a frequent Swamper
EESignature
Message 9 of 11
kbarnettza
in reply to: Jeff_M

has it appeared in C3D 2019 API? ... if not ... maybe coming next year?

Message 10 of 11
ralstogj
in reply to: kbarnettza

NO updates to the API I know of have discussed a possible way of doing it in the AUGI forums here

 

http://forums.augi.com/showthread.php?157034-NET-API-functions-to-interrogated-Civil-3D-drawings-for...

 

Justin

Regards

Justin Ralston
http://c3dxtreme.blogspot.com/
Message 11 of 11
kbarnettza
in reply to: ralstogj

Thx Justin .

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


 

Autodesk Design & Make Report