excel vba - Before_RightClick runs (custom popup menu), and the ctrl options are set, but the popup stays constant -


i have user code not affect, others runs fine.

    private sub worksheet_beforerightclick(byval target range, cancel boolean)     each ctrl in application.commandbars("cell").controls         if ctrl.builtin , ctrl.caption <> "&copy" , ctrl.caption <> "&paste"             ctrl.visible = false         else             ctrl.visible = true         end if     next ctrl     end sub 

the code executes (i added break, , watch of controls show visible value being changed) end result of popup default excel popup.

could assist in finding wrong?

i ran: application.commandbars("cell").reset , application.commandbars("cell").enabled = true not fixed.


Comments

Popular posts from this blog

Android : Making Listview full screen -

javascript - Parse JSON from the body of the POST -

javascript - Chrome Extension: Interacting with iframe embedded within popup -