Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Run macro on all drawings

Status
Not open for further replies.

ACGraff1217

Mechanical
Apr 14, 2015
1
0
0
Hello All,

I am new to this forum and very new to writing macros. I am in great need of help because I am stuck so any help and advice would be greatly appreciated.

I am going through and deleting a revision and adding a revision block to all drawings for a large assembly. I have created a macro that does that but currently I have to open every drawing individually and run it. On smaller assemblies this is not a problem but many of the assemblies I need to do are 400 or more drawings. I do not need to gather any data from the old revision blocks, I just need to delete them and add a new blank block in. I have spent several hours digging around this forum and others digging through code and putting bits and pieces together but have had no luck.

What I have:
A macro that deletes and adds a new revision block.

What I need:
I need open each drawing file in a folder, run my macro, save the drawing and close the drawing.

At this point I don't even need it to ask for the directory I want top work in, I can edit that in the code. Maybe later on when workload is lighter I will try to learn how to prompt the user for folder path so I am not the only one who can use this macro where I work.

Thank you all in advance for your time

Kind Regards,
Alex G
 
Replies continue below

Recommended for you

Status
Not open for further replies.
Back
Top