How do you use 7 viewports with Function keys

HI, I am trying to use functions to change to any of the 7 views, (top, Bottom, Left, Right, Front, Back, and Perspective). Right now, I can only use control F1, F2. F3, and F4 to get Top, Front, Right, and Perspective. If I Write a Macro for Bottom, Left, and Back, with function keys F5, F6, F7, none of them will work. It just says unable to find viewport name. Maybe I need to write the Macros a different way.

It basically will only let me toggle between 4 views, no more. Maybe someone else has experience with this. This Rhino 6, but It does the same thing in Rhino 5.

Hi John - do you want to activate an existing viewport or change the current view? SetActiveViewport "Bottom" assuming Bottom is the name of an existing vp.
SetView World Bottom to set the current vp to Bottom…

Any of that help?

-Pascal

See if this works for you:

Hi John, I put in those Macros and starting from the 4 view ports open, the first 4 work but the next 3 dont, and then only 2 of the first 4 work, and none of the next 5. It seems all over the place on what works. mostly just Unable to find viewport

Hmmm… I’ll look a little more closely…

Right - those macros are looking for viewports with those names. If the vps do not exist, then they fail.

-Pascal

Assuming the file only had a single viewport with an unknown name, then this should work

Well It almost worked.It goes though the command line and goes to some of the views, but then it ends up going to top view on every one of the function keys even though on the Command line it says it is going to all of the different views.

I pounded on it a lot and it’s not having those problems here.
When your display gets into that “stuck” Top view, does a little right-click and drag Pan to giggle the display update it?

In the parallel display views, the only thing that might change will be the World Coordinate icon in the corner, and of course your model geometry.

You might want to add a Zoom argument to these macros too.

As Im watching the screen, and going though the F keys on the different views, It actually goes to the proper view for a split second, then It flashes to top view.

Im not a programer at all, just a CAD guy, but it seems to me that If I can push an Icon Button and make it go to the different views then there should be a code that can go into a key board stroke

Hi John - I guess the answer to the question I asked above is ‘I want to set the current view to X’ and not ‘I want the existing viewport named X to become active’, correct? If that is correct use

SetView World Bottom (Top Left etc etc.)

You might also like the OneView command.

-Pascal

Maybe '_SetView World Top/Bottom/Left/Right/Front/Back/Perspective is all the macro needs to do.
If the view is already maximized, that should just change the view.

Ctrl + F1 '_SetView World Top

1 Like

That worked. Thanks to both of you.