Author Topic: Project-Auditing dwgs to a CAD Standard  (Read 31426 times)

0 Members and 1 Guest are viewing this topic.

David Hall

  • Automatic Duh Generator
  • King Gator
  • Posts: 4075
Project-Auditing dwgs to a CAD Standard
« on: July 21, 2008, 06:28:10 PM »
Anyone interested in helping me create a auditing tool to check drawings against a corporate standard is welcome to help.  I'm thinking we should write this in C#, as its seems to be the way of the future, and you guys are making huge leaps already.

These are some of the things I'm trying to accomplish, feel free to add to the list

  • Layers- Names/Color/Linetype
  • Text Styles
  • Titleblock/info block properties-correct layer, insertion point, etc.
  • Image props-correct layer, insertion point, etc
  • Dimension Style settings
  • Use of Mtext vs Dtext, Null text strings
  • XREF props-correct layer, insertion point, relative pathing, etc
  • Everything By Layer
  • Revisions using double digits( 01, not 1)
Everyone has a photographic memory, Some just don't have film.
They say money can't buy happiness, but it can buy Bacon and that's a close second.
Sometimes the question is more important than the answer. (Thanks Kerry for reminding me)

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #1 on: July 22, 2008, 07:58:50 AM »
Attached is a skeleton/test harness for selecting bulk drawings and then running over them, loading each into memory (not graphically) and doing some sort of processing.

This is to get the project and discussions started. Once people have digested the code, please post your comments on how you would design this checker.

Some of my initial thoughts:

XML based rules file(s) maybe?
These would contain things to check and also location of DWS files for compliance checking?

Have at it lads.

Cheers,

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #2 on: July 22, 2008, 08:00:36 AM »
Forgot to mention. The attached project in my post above, was produced using Visual C# 2008 Express against the .NET 3.5 framework and AutoCAD 2006, although it should run on 2006 and upwards.

HD

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #3 on: July 22, 2008, 09:01:16 AM »
Glenn,

Very nice! Thank you for taking the time to start this program.

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #4 on: July 22, 2008, 09:04:06 AM »
No probs Nick. Hopefully it will stimulate some interest.

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #5 on: July 22, 2008, 09:10:49 AM »
We'll also have to agree on what output is required and in what format. I think XML with an XSLT transform to make the report pretty.

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #6 on: July 22, 2008, 09:11:52 AM »
Anybody reading this good with XSLT transforms?

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #7 on: July 22, 2008, 09:12:12 AM »
Oh the silence is deafening! :)

David Hall

  • Automatic Duh Generator
  • King Gator
  • Posts: 4075
Re: Project-Auditing dwgs to a CAD Standard
« Reply #8 on: July 22, 2008, 09:15:33 AM »
I need to get caught up, going to read the code
Everyone has a photographic memory, Some just don't have film.
They say money can't buy happiness, but it can buy Bacon and that's a close second.
Sometimes the question is more important than the answer. (Thanks Kerry for reminding me)

vegbruiser

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #9 on: July 22, 2008, 09:58:02 AM »
You must've read my mind CmdrDuh. I've been working on this exact problem for about 6 weeks or so (there's not much else to do at the moment, so the boss hasn't batted an eyelid)

Attached is what I've got thus far. The parts you might be interested in are where I output the information gathered from a selection of Excel and AutoCAD files to XML.

What I haven't got around to figuring out yet is how to check for viewports (scale & view location)/layers (conformance to a given standard)/ blocks (attributes filled out correctly, correct blocks used).

Unfortunately, my code is VB.NET, but I'm happy to convert it to C# if people think it might be useful.

Actually, scratch all that, I'll extract (and convert) the parts that write the XML file(s) as the rest is specific to my situation. (I'd still appreciate it if anyone does take the time to read through my code though, as I'm certainly no expert, and all constructive criticism will be gratefully accepted)

I'll post the relevant parts as soon as I've read what GlennR posted. :)
« Last Edit: July 22, 2008, 10:04:35 AM by vegbruiser »

David Hall

  • Automatic Duh Generator
  • King Gator
  • Posts: 4075
Re: Project-Auditing dwgs to a CAD Standard
« Reply #10 on: July 22, 2008, 10:22:37 AM »
I think XML is definelty the way to go for the files.  Kerry has shown me some great examples of how to put stuff in XML that makes organization easier.
Everyone has a photographic memory, Some just don't have film.
They say money can't buy happiness, but it can buy Bacon and that's a close second.
Sometimes the question is more important than the answer. (Thanks Kerry for reminding me)

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #11 on: July 22, 2008, 10:25:57 AM »
Well have at it then laddy! Get an initial design together and post it so we can continue discussions.

Glenn R

  • Guest
Re: Project-Auditing dwgs to a CAD Standard
« Reply #12 on: July 22, 2008, 10:27:16 AM »
I meant the XML btw. We may as well use some LINQage for querying the XML files whilst we're at it...

David Hall

  • Automatic Duh Generator
  • King Gator
  • Posts: 4075
Re: Project-Auditing dwgs to a CAD Standard
« Reply #13 on: July 22, 2008, 10:28:14 AM »
So do we have the list of what we want to check finished?
Everyone has a photographic memory, Some just don't have film.
They say money can't buy happiness, but it can buy Bacon and that's a close second.
Sometimes the question is more important than the answer. (Thanks Kerry for reminding me)

David Hall

  • Automatic Duh Generator
  • King Gator
  • Posts: 4075
Re: Project-Auditing dwgs to a CAD Standard
« Reply #14 on: July 22, 2008, 10:29:30 AM »
Also, are we checking things that the Standards checker already does?  The reason I ask is your reference to the DWS files above.
Everyone has a photographic memory, Some just don't have film.
They say money can't buy happiness, but it can buy Bacon and that's a close second.
Sometimes the question is more important than the answer. (Thanks Kerry for reminding me)