|
* 답변하시는 분들께 도움이 되도록 자신의 환경을 아래 항목 옆에 기재해 주세요.
- 엑셀 버전(95,97,2000,xp,2003,2007):
* 아래줄에 질문을 작성하세요 >>
1. 아래와 같이 하면 추가메뉴가 생기고 전체가 다 나와서 해당시트에 해당하
는 메뉴만 나타내고 싶은데요..
방법이 없겠습니까 ?
부탁 드립니다.
2. office Ribbon 메뉴를 사용할려고 하니 실행에러나 나는데요..
혹시나 어디가 문제 인지알수 있을까요 ?
Sub dhMakeMenu()
Dim c As CommandBarControl
Dim i As Integer
With Application.CommandBars(1)
i = .Controls.Count
Set c = .FindControl(Type:=msoControlPopup, Tag:=strN)
If c Is Nothing Then
Set c = .Controls.Add(Type:=msoControlPopup, before:=i)
With c
.Caption = strN & "(&S)"
.Tag = strN
With .Controls.Add(Type:=msoControlPopup)
.Caption = "입고 등록하기"
With .Controls.Add(Type:=msoControlButton)
.Caption = "입고 등록"
.OnAction = "입고등록_insert"
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "수식적용"
.OnAction = "입고_수식"
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "입고 등록 대기"
.OnAction = "입고등록_초기화"
End With
End With
With .Controls.Add(Type:=msoControlButton)
End With
With .Controls.Add(Type:=msoControlPopup)
.Caption = "입고 수정하기"
With .Controls.Add(Type:=msoControlButton)
.Caption = "조 회 하 기"
.OnAction = "입고_Insert_Search"
End With
With .Controls.Add(Type:=msoControlButton)
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "입고정보 수정하기"
.OnAction = "입고등록_Insert_Update"
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "입고정보 삭제하기"
.OnAction = "입고_삭제"
End With
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "-----------------------"
End With
With .Controls.Add(Type:=msoControlPopup)
.Caption = "사급 등록하기"
With .Controls.Add(Type:=msoControlButton)
.Caption = "사급 등록"
.OnAction = "조회확인"
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "사급 등록 대기"
.OnAction = "사급_등록_초기화"
End With
End With
With .Controls.Add(Type:=msoControlButton)
End With
With .Controls.Add(Type:=msoControlPopup)
.Caption = "사급 수정하기"
With .Controls.Add(Type:=msoControlButton)
.Caption = "조 회 하 기"
.OnAction = "사급_입출고_Search"
End With
With .Controls.Add(Type:=msoControlButton)
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "사급 수정하기"
.OnAction = "사급_Insert_Update"
End With
With .Controls.Add(Type:=msoControlButton)
.Caption = "사급 삭제하기"
.OnAction = "사급_Delete"
End With
End With
' End With
' End With
End With
End If
End With
Set c = Nothing
End Sub |
|