Action Record not working

Action Record not working

Amriya_Exe
Advocate Advocate
8,200 Views
9 Replies
Message 1 of 10

Action Record not working

Amriya_Exe
Advocate
Advocate

I want to switch my to next layout and Zoom extend.

I was doing this manually for all 100 Layouts then I tried to record action and switched one layout and did zoom extend after stop recording I saved action. 
And playing that action but not happening anything.


Is it right way to use that action recoding option? 

0 Likes
Accepted solutions (1)
8,201 Views
9 Replies
Replies (9)
Message 2 of 10

paullimapa
Mentor
Mentor

Could be because the action recorded just repeated the same command on the same layout. I’d use lisp to cycle through each layout and run the zoom command like this:

(foreach Layout (layoutlist)(setvar "ctab" Layout)(command "_.Zoom" "_E"))

Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 3 of 10

Amriya_Exe
Advocate
Advocate
This will switch to next layout automatic?
0 Likes
Message 4 of 10

paullimapa
Mentor
Mentor

Yes This will automatically switch to all your layouts and do a zoom extents. Try it on a dwg with a couple of layouts first just to see how it works 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 5 of 10

Sea-Haven
Mentor
Mentor

Unfortunately you have to go to each layout to do a Zoom E, but its surprisingly fast, had a dwg with 88 layouts, don't watch it blinks to much. 😁 

 

As a last step decide (setvar 'ctab "Model") or a layout you want. Else will stop at last layout.

0 Likes
Message 6 of 10

Amriya_Exe
Advocate
Advocate
I am recording macros for Some properties modify of particular Object in all layouts.
how can I add switch to next layout in recording.
0 Likes
Message 7 of 10

paullimapa
Mentor
Mentor
Accepted solution

Don't think action recorder works that way. What you can do is record the action you want for a typical layout.

Then you have to manually select a layout and then run that action again.


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 8 of 10

Amriya_Exe
Advocate
Advocate
Yes Trying same now.. I understood.
You know if I record macros action then convert it into Script and adjust script as per required?
0 Likes
Message 9 of 10

paullimapa
Mentor
Mentor

Unfortunately there’s no tool that can convert action recorder to script 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
Message 10 of 10

Sea-Haven
Mentor
Mentor

Like paullimapa give up on action recorder, bit of a waste of time who ever at Autodesk thought it would be a great tool needs to look at it again, interesting though another Cad package its action recorder writes VBA code which is very useful and can be edited. Look at  Excel macro's vba code, the probable reason is that Autodesk announced VBA will be discontinued, yeah let me think was it 5 years ago, its still in 2024 ?

 

Re doing things in multi layouts, some examples

Zoom All

Move extents to 0,0

Update sheet numbers

Update multi titles across all layouts

Plot layouts by range

Goto layout see attached

Can find a few more if I look

 

Others will have lots of other handy functions used every day, so ask what do you want to do across your layouts.

0 Likes