Hi. I'm trying to make a macro that will do the following actions for each part I mark in the assembly.
The actions are:
open the part, zoom to fit, save, open the drawing, save, save as PDF, close the drawing, close the part.
When I run the macro I recorded, I get a message - Run-time error '91': and also a message Object variable or With block variable not set.
I see in the code that there are several places with the name of the file on which I made the macro.
For example: swApp.ActivateDoc2 "RS-00-003.SLDPRT", False, longstatus
or
Set Part = swApp.OpenDoc6("G:\RAFI\RS-00-003.SLDDRW", 3, 0, "", longstatus, longwarnings)
What do I need to do, to record without file names and locations? So that I can perform all the above actions on any part I want in the assy?
Thanks for the help