How to comment and uncomment blocks of code in the Office VBA Editor

后端 未结 9 823
醉酒成梦
醉酒成梦 2020-12-02 04:21

In the VBA editor of Office (ALT + F11), how do you comment or uncomment a block of code?

9条回答
  •  情书的邮戳
    2020-12-02 04:55

    There is a built-in Edit toolbar in the VBA editor that has the Comment Block and Uncomment Block buttons by default, and other useful tools.

    If you right-click any toolbar or menu (or go to the View menu > Toolbars), you will see a list of available toolbars (above the "Customize..." option). The Standard toolbar is selected by default. Select the Edit toolbar and the new toolbar will appear, with the Comment Block buttons in the middle.

    enter image description here

    *This is a simpler option to the ones mentioned.

提交回复
热议问题