How to create "Wireframe on shaded" hotkey shortcut in Maya

Something usefull for those want to save time in Maya ;) The script is not from me but I would like to share it
Let's start !

Something usefull for those want to save time in Maya ;) The script is not from me but I would like to share it
Let's start !

Open the Hotkey editor ( Windows/ Settings/Preferences/ Hotkey Editor), and click on the "Runtime Command Editor" tab on the right side of the window.

Open the Hotkey editor ( Windows/ Settings/Preferences/ Hotkey Editor), and click on the "Runtime Command Editor" tab on the right side of the window.

1. Click the "New" button.
2. Type a name for your command in the "Name" field.
3. Copy the script below and Paste it in the script window.
string $selectedPanel = `getPanel -wf`;
int $shadedWireState = `modelEditor -q -wos $selectedPanel`;if(`modelEditor -ex $selectedPanel`)
{
setWireframeOnShadedOption (!$shadedWireState) $selectedPanel;
}
4. Click the "Save Runtime Command" button.
5. Select the " Edit Hotkeys for" option and select "Custom Scripts". Then click on the command and enter your Hotkey shorcut.
6. Click the "Save" or "Save and Close" button

Hope that helps you, Cheers!