I use a macro to cut and paste my 2D drawing onto a layout tab (called “RIT”) and the macro also allows me to place the drawing at a specific position;
The problem is that the macro stops after “…_SetActiveViewport RIT” and the rest of the macro, “_Paste _Move 0” is not printed in the command bar.
I asked about this in a previous topic; Make2D macro suddenly stopped working
It worked for a while after a fix suggested by @pascal but now it has stopped again.
There seems to be a problem with the “SetActiveViewport” command?
Maybe this function would be more stable as a script?
To me, it looks more like there’s a problem with the Paste command. I can run a different command after the SetActiveViewport without problems, but even then, pasting doesn’t work.
I’ve put this on the list as RH-72471 Paste: Doesn’t work in macro
-wim
Thanks for the reply! I’m not so sure “_Paste” is the problem because “_Move _Pause _Pause _Pause _Paste”
works without problems. The “_Paste” command worked if I changed the active viewport on the same tab (from Perspective to Front ) I tried; ! _-Make2d _Pause _Enter _SelNone _SelLast _Group _Cut _SetActiveViewport Front _Paste _Move 0
and it works. It seems more likely that switching tabs causes the macro to end?
This is so weird. As with your previous topic that you referred to in the first post in this thread, that doesn’t work at all on my system. Here, your updated macro to paste in the Front viewport gets stuck in the Move command…
Especially strange is that the box is selected but the Make2D info is on the clipboard…
-wim
I see.
What you are (and I am) obviously looking for, is an option for Make2D to target layouts. This seems to be on the wishlist here, but incomplete. Maybe this is an opportunity to gather some traction for it.
Besides, maybe a script is the better option than a macro in this case?
Yes a script would be the best option but Make2D in script seems to be very complicated to write and I am no scripter… Do anyone know if there is a way to change active rhino viewport or tab via Grasshopper?