.NET

Reply
Active Contributor
murali.pandey
Posts: 31
Registered: ‎12-18-2008
Message 1 of 8 (487 Views)

compare drawings

487 Views, 7 Replies
04-25-2012 01:15 AM

Can any one tell me How to compare two drawing file with object data(two version of the same drawing) .if any body has source code (C# Arx) then will be much better.

 

Thanks

Murali

Moderator
Alexander.Rivilis
Posts: 1,417
Registered: ‎04-09-2008
Message 2 of 8 (483 Views)

Re: compare drawings

04-25-2012 02:06 AM in reply to: murali.pandey

If you can explain in great detail what is "to compare the drawings" I'll try to help you. 


Пожалуйста не забывайте про Утвердить в качестве решения! Утвердить в качестве решения и Give Kudos!Баллы
Please remember to Accept Solution! Accept as Solution and Give Kudos!Kudos

Active Contributor
murali.pandey
Posts: 31
Registered: ‎12-18-2008
Message 3 of 8 (477 Views)

Re: compare drawings

04-25-2012 02:16 AM in reply to: Alexander.Rivilis

ok..suppose I have drawing A ..Now I have made some changes in drawing A(like addition/deletion/object data modification)  and save it as Drawing B. Now I want to compare Drawing A and B to find out the changes and mark those changes in a temporary drawing.

 

Thanks

Murali

Moderator
Alexander.Rivilis
Posts: 1,417
Registered: ‎04-09-2008
Message 4 of 8 (472 Views)

Re: compare drawings

04-25-2012 02:33 AM in reply to: murali.pandey

1. Iterate model space (and other layout if needed).

2. Collect ObjectID's for all entities in both dwg files.

3. Compare collection of ObjectID's, find deleted/added entities (compare not ObjectID but Handle value)

4. Compare entities with the same Handle from both dwg file. It is easy compare entitytype, layer, color, linetype, etc., but not easy compare geometry of entities.

 


Пожалуйста не забывайте про Утвердить в качестве решения! Утвердить в качестве решения и Give Kudos!Баллы
Please remember to Accept Solution! Accept as Solution and Give Kudos!Kudos

Active Contributor
murali.pandey
Posts: 31
Registered: ‎12-18-2008
Message 5 of 8 (469 Views)

Re: compare drawings

04-25-2012 02:44 AM in reply to: Alexander.Rivilis

Thanks..actually major issue with the object data copmarison.should I have to open both the dwg in the current session?

If you have sample code..will b good for me.

 

Thanks

Murali

Moderator
Alexander.Rivilis
Posts: 1,417
Registered: ‎04-09-2008
Message 6 of 8 (463 Views)

Re: compare drawings

04-25-2012 02:58 AM in reply to: murali.pandey

murali.pandey wrote:

...should I have to open both the dwg in the current session?...


Yes.


Пожалуйста не забывайте про Утвердить в качестве решения! Утвердить в качестве решения и Give Kudos!Баллы
Please remember to Accept Solution! Accept as Solution and Give Kudos!Kudos

*Expert Elite*
arcticad
Posts: 1,285
Registered: ‎06-21-2004
Message 7 of 8 (439 Views)

Re: compare drawings

04-25-2012 08:26 AM in reply to: Alexander.Rivilis

is there a way to iterate over all the different properties of an object, without having to specifically specify each one. Such as height , width. just use the properties that would normally show up in the properties in Visual Studio.

 

I know this is probably a long shot.

Thanks.

 

---------------------------



(defun botsbuildbots() (botsbuildbots))
Valued Mentor
jeff
Posts: 330
Registered: ‎05-12-2009
Message 8 of 8 (434 Views)

Re: compare drawings

04-25-2012 09:36 AM in reply to: arcticad

You could use reflection or create a filer.

 

Here was attempt that was thrown together as a intial test just to see how it worked but I think I wiould take another approach.

http://www.theswamp.org/index.php?topic=39991.0

It used handles to compare so the idea was for comparing diffrent versions of the same drawing.

It might be better to go with a DxfFiler that which looks like it overrides might be eaiser for creating some type of structure for comparing.

 

If you look at Tony T posts here

http://www.theswamp.org/index.php?topic=41311.0

http://www.theswamp.org/index.php?topic=41371.0

 

 

You could maybe use LINQ to group types, and figure a way to test some properties and get more specidic as needed like using curve properties for lines, polylines, and get more specific for ones that pass.

 

Or somehow mix the two where you file out info that would make comparing eaiser.

 

 

 

You can also find your answers @ TheSwamp
Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.