Getting the snap palette to pop up under the cursor

On a multi-button mouse, in the Preferences>Mouse>Buttons section, how does one program a tool palette popup (say under button #6)?


_ToggleOsnapPanelUnderCursor is the command for the Osnaps panel.

For tool palettes, use the example here. This can be used with any button you choose.