Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在代码模块中(命名功能区)
Sub Form1Show(control As IRibbonControl) ' this is custom ribbon Form1.Show ' works End Sub
在 ThisWorkbook 模块中:
Private Sub Workbook_Open() Call Form1.Show ' error: argument not optional End Sub
有人可以解释一下吗?
将参数声明为可选;否则,它是必需的。
Sub Form1Show(Optional control As IRibbonControl)