LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Floating Command Button

Jim,

I have taken your example and tried to create a Floating Command Bar (Shown
Below). I am guessing that I have done something wrong, because I get
nothing. Please Help!!!

Sub CommandButton97_Click()
'
' CommandButton97_Click Macro
' Macro recorded 5/6/2008 by g141183
'

Application.Goto Reference:=Worksheets("Master Report").Range("A1"),
Scroll:=True

End Sub

-----------------------------------------------------------------------------------------
Sub Scroll31Right()
ActiveWindow.SmallScroll Toright:=31
End Sub

-----------------------------------------------------------------------------------------
Sub Scroll31Left()
ActiveWindow.SmallScroll Toleft:=31
End Sub

-----------------------------------------------------------------------------------------
Sub MakeFloatingCommandbar()
On Error Resume Next
CommandBars("MyCB").Delete
On Error GoTo 0
CommandBars.Add "MyCB", msoBarFloating, , True
With CommandBars("MyCB")
With .Controls.Add(msoControlButton)
.Caption = "Right"
.FaceId = 80
.OnAction = "Scroll31Right()"
End With
With .Controls.Add(msoControlButton)
.Caption = "Left"
.FaceId = 81
.OnAction = "Scroll31Left()"
End With
With .Controls.Add(msoControlButton)
.Caption = "Main"
.FaceId = 83
.OnAction = "CommandButton97_Click()"
End With
.Visible = True
End With
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
Floating Command button kev_06[_15_] Excel Programming 4 June 13th 06 11:10 PM
Floating command button Pat Excel Discussion (Misc queries) 4 April 7th 06 01:28 PM
Create floating button based on button click in menu ExcelMonkey Excel Programming 2 October 12th 05 06:43 PM
How can I create a Floating Command Button Karoo News Excel Programming 1 August 19th 05 11:19 AM
Floating Command Button - How to??? TinyTim Excel Programming 6 January 2nd 04 07:23 AM


All times are GMT +1. The time now is 06:24 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"