I found this at https://wiki.lxde.org/en/Main_Menu under the refreshing the menu section. This kills and restarts lxpanel.
Is it possible to hard reboot your computer (for a modern, ACPI-compliant system usually holding down the power button for multiple seconds cuts the power to the components, after which it can be booted up normally assuming no file writes were interrupted) I suggest you only use this if your computer really is not responding, it can occasionally cause filesystem corruption.
For lxpanel try:
#!/bin/bash
killall lxpanel
find ~/.cache/menus -name '*' -type f -print0 | xargs -0 rm
lxpanel -p LXDE &
If you want to copy/paste directly, then use my modified one-liner:
killall lxpanel && find ~/.cache/menus -name '*' -type f -print0 | xargs -0 rm && lxpanel -p LXDE &
I don't know about openbox, though.