LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default More help with Custom menu's 2 problems!


First of all i would like to thank all that have helped so far, you are all
a credit to this news group many thanks...

My next problem is this code did work but now does not. I get no custom menu
but when it did the custom menu displayed no text only Icon's when using
button's, it worked fine with popup's the text was displayed but I only need
button's!


Dim Cbar As CommandBar

Private Sub Workbook_Activate()
With Application
.Caption = " 'ERP Scanner Connected Spreasheet'" _
& " - Created By Neil Atkinson - Workbook Name:"
.OnKey key:="{F1}"
.OnKey key:="{F5}"
.OnKey "^{s}", ""
.OnKey "^{p}", ""
.DisplayFormulaBar = False
End With
Application.OnKey "^{s}", ""
Application.OnKey "^{p}", ""
Application.MoveAfterReturn = True
Application.MoveAfterReturnDirection = xlDown
Worksheets(1).ScrollArea = "B1:B1000"

For Each Cbar In Application.CommandBars
If Cbar.BuiltIn = True Then
Cbar.Enabled = False
End If
Next

Application.CommandBars.DisableCustomize = True

Call MyMenu

End Sub

---------------------------------------------------------------

Sub MyMenu()

On Error Resume Next

Dim myMenuBar As CommandBar
Dim aMenu As Object

Set myMenuBar = CommandBars.Add(Name:="ERP", _
MenuBar:=True, temporary:=True)

With myMenuBar.Controls
Set aMenu = .Add(Type:=msoControlButton, temporary:=True)
aMenu.Caption = "&HANDSETS"
aMenu.TooltipText = "Click to enter Handsets"
aMenu.OnAction = "Handsets"
aMenu.FaceId = 568
End With
With myMenuBar.Controls
Set aMenu = .Add(Type:=msoControlButton, temporary:=True)
aMenu.Caption = "&SIMS"
aMenu.TooltipText = "Click to Enter SIM Cards"
aMenu.OnAction = "SIMS"
End With
With myMenuBar.Controls
Set aMenu = .Add(Type:=msoControlButton, temporary:=True)
aMenu.Caption = "&VOUCHERS"
aMenu.TooltipText = "Click to enter Vouchers"
aMenu.OnAction = "Vocuhers"
aMenu.FaceId = 1826
End With
With myMenuBar.Controls
Set aMenu = .Add(Type:=msoControlButton, temporary:=True)
aMenu.Caption = "&COPY to 'serialno.txt'"
aMenu.TooltipText = "Copy contents to C:/MCL-col/Link/Data location"
aMenu.OnAction = "CopyToSN"
aMenu.FaceId = 270
End With

myMenuBar.Visible = True

End Sub

-----------------------------------------------------------------



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Picture problems in custom header DDawson Excel Discussion (Misc queries) 0 March 11th 08 12:10 PM
Custom Menu's Fgomez Excel Discussion (Misc queries) 1 April 19th 05 02:43 PM
Custom menu problems Andrew Fletcher Excel Programming 5 April 3rd 05 01:42 PM
Custom function problems Andrew B[_2_] Excel Programming 0 June 17th 04 05:20 AM
Custom menu's Stu[_33_] Excel Programming 3 April 1st 04 10:02 PM


All times are GMT +1. The time now is 02:07 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"