I'll have to admit my second point was rather unclear. I meant you should put the conditional code directly into the OnShow of the root.
There is no need to escape a semi-colon, I do not think it has any reserved meaning in a value (which also means you have no need to use it). I usually separate commands via line breaks. This should work:
menuButton.OnPress=(MenuEntry.menuaction) ## '
togglestartmenu'