Macros from the past: Part 1 (AutoCAD Batch Mode)

I was doing some early spring cleaning on my backup drive and found some old remnants of past AutoCAD and Inventor macros that I thought would be cool to share. I’m going to share these one per blog post. None of these are really functional anymore and some only exist as saved screenshots  but it’s neat to see what’s possible with some good ole’ fashion, down and dirty coding.

The first is a Batch Mode Operations tool for AutoCAD. This macro was used to batch process an entire folder of drawings by updating the drawing number and renaming the file. It also could update some title block attributes. This tool was used to copy an entire projects design from one plant location to be used in another plant location. Since the designs had the tendency to diverge once the equipment was installed, the drawings needed to be separate
and unique. It would have consumed a  few weeks of someone’s time to copy out the files, rename them and update the title block values. This batch tool could accomplish the same task within a few minutes.

The other function of the macro was to batch extract title block attributes to an Access database. The macro would create a database in the selected folder if one did not exist already. The macro allowed you to add the attributes from the files or update the values if the filename already existed in the database. You could also remove entries based on the current batch. This allowed you to keep your drawing properties synched to the database. I was in the process of adding the functionality to feed the database properties back to the drawings when the project was shelved.

Here’s what the exported database would look like:

This entire tool was completely designed in VBA (Visual Basic for Applications) for AutoCAD (circa 2001 or so). Next set of posts, I’ll show you some more cool tools you develop using VBA. I’m so glad I save everything. Now I just wish I would have saved the actual macros.

VN:F [1.9.22_1171]
Rating: 4.3/5 (4 votes cast)

Permanent link to this article: http://cadtoolbox.com/2011/02/24/macros/

iLogic – Triggers, Rules and Templates… oh my.

iLogic is a great tool for Inventor. It allows for rules driven design that automates and standardizes functions of Inventor. These rules can control many different aspects of a model or Inventor drawing. Rules can be either stored within the individual CAD file or an external iLogic file that can be reused on multiple files. You can read more about iLogic on the Autodesk WikiHelp site.

Rules must be applied to the event triggers you want to fire them with, such as on save, iProperty change, etc. Each file you work with can be customized as to what rules apply to what triggers. You apply a rule to a trigger by clicking on the event trigger and selecting the rules you want to apply. So each file you work with would need the rules applied to each trigger you want to use. There is currently no streamlined method for applying a rule to an event by default. This makes iLogic as a tool to enforce company wide rules somewhat difficult to configure to large groups of people efficiently in its current incarnation.

A workaround is to save the rules applied to the appropriate triggers into your standard template files. Each time a new file is created using these templates, the rules will be applied correctly to the triggers and fire when desired. This doesn’t help you with existing files and doesn’t give you a good method to make future edits or additions.

The word from Autodesk so far is that iLogic, being an add-in acquired from a acquisition has not fully been integrated into Inventor yet. You can get an idea of this just in the look and feel of the dialog windows not being integrated into the look and workflow of Inventor. I’m sure we’ll see some big improvement with iLogic in the 2012 and 2013 releases. Keeping my fingers crossed.

VN:F [1.9.22_1171]
Rating: 0.0/5 (0 votes cast)

Permanent link to this article: http://cadtoolbox.com/2011/02/15/ilogic/

Vault – Search & Find

From Brian Schanen (Under the Hood): 

The ability to search and find files is a powerful part of Autodesk Vault. Watch this video as Markus takes us through best practices and tips for using the Search capabilities in Vault.

httpv://www.youtube.com/watch?v=8owcp0hrLcg

VN:F [1.9.22_1171]
Rating: 0.0/5 (0 votes cast)

Permanent link to this article: http://cadtoolbox.com/2011/02/02/vault-search-find/

Tuesday Wrap-up

If you just don’t have time to surf the latest on what’s new in Autodesk land, check out these highlites from the week so far:

Autodesk releases TinkerBox for iPad

TinkerBox is a fun, free-to-play physics puzzle game. While it is full of interesting science facts and teaches basic engineering concepts, TinkerBox is more than just educational!

httpv://www.youtube.com/watch?v=_9lceUdBddA&feature=player_embedded
[ Autodesk TinkerBox Information | iTunes Store ]

Will it Break? Episode 1 from Rob Cohee on Autodesk Simulation

Here’s an excerpt from my Autodesk University MFG Keynote: “So before I end, I want to briefly talk about simulation and the tools that we are working on that are quite frankly amazing in their capabilities and the speed in which you can solve some of the most common engineering challenges. Now don’t confuse common with simple – common in that we all need to know – “Will it break?” “How does air move around my part”, “When will it fail?”, or “How light can I make this?””

httpv://www.youtube.com/watch?v=s9CmOpQRKXg&feature=player_embedded
[ Read the Blog Post ]

Read the rest of this entry »

VN:F [1.9.22_1171]
Rating: 4.0/5 (2 votes cast)

Permanent link to this article: http://cadtoolbox.com/2011/02/01/tuesday-wrap-up/

Page 40 of 67« First...102030...3839404142...5060...Last »