|
Как добавить вложенную кнопку
|
|||
---|---|---|---|
#18+
Народ, пишу AddIn для редактора Visual Basic. Добавляю свой пункт меню, пункт добавляется, а как добавить вложенный пункт???? Как только не пробывал, не работает и все тут. Вот код: код Option Explicit Dim VBInstance As VBIDE.VBE Dim cbAddIns As CommandBar Dim cbcInsertLine As CommandBarControl Private WithEvents cbeInsertLine As CommandBarEvents Private Sub AddinInstance_OnConnection(ByVal Application As Object, ByVal ConnectMode As AddInDesignerObjects.ext_ConnectMode, ByVal AddInInst As Object, custom() As Variant) Set VBInstance = Application ' Find the Add-Ins menu. Set cbAddIns = VBInstance.CommandBars("Add-Ins") ' Add a button to the Add-Ins menu. Set cbcInsertLine = cbAddIns.Controls.Add(Type:=msoControlButton) ' Assign the Caption and Style of the new button. cbcInsertLine.Caption = "SQL-code" cbcInsertLine.Style = msoButtonCaption ' Associate an event object to the new button. Set cbeInsertLine = VBInstance.Events.CommandBarEvents(cbcInsertLine) End Sub ... |
|||
:
Нравится:
Не нравится:
|
|||
14.12.2010, 12:07 |
|
|
start [/forum/topic.php?fid=60&gotonew=1&tid=2159156]: |
0ms |
get settings: |
11ms |
get forum list: |
15ms |
check forum access: |
4ms |
check topic access: |
4ms |
track hit: |
39ms |
get topic data: |
13ms |
get first new msg: |
9ms |
get forum data: |
3ms |
get page messages: |
36ms |
get tp. blocked users: |
2ms |
others: | 13ms |
total: | 149ms |
0 / 0 |