Creating a New Button to do 2 functions

I have a custom button I made that does this function '_SetDisplayMode _Mode=_New Mode

and I have a 2nd custom button I made that does
! _Print

Is it possible to make 1 button to do both function in the order listed bellow? I am trying to save 2 mouse clicks and do 1 mouse click.
'_SetDisplayMode _Mode=_New Mode
! _Print

Hi Roger -

You’ll have to drop the underscore and space in the name of the display mode for this to work.

'_SetDisplayMode _Mode=NewMode
_Print

-wim

Is there a code to close Rhino ?

I want to make that the next step.

Hi Roger - Exit will close Rhino.

-Pascal

Thank you !!!

Is there a code to Select a the Perspective Viewport ?

Also is there a code to Select the answer NO when asked a question with the options Yes or No popup

Hello- it is starting to seem like you might want to type some Python script -

NextPerspectiveViewport

should help.

-Pascal

Thank you so much

I am sorry , was there a code for
When a question pops up asking YES or No to Select No?

This is my last question i promise :slight_smile:

Hi Roger -

When you are getting a pop-up, you’ve left the world of macros.
Generally, you can suppress dialogs by using a dash in front of a command.
Also see the help file on macros: Rhinoceros Help
-wim

I tried it and it worked. Thank you so much !