Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
i want to programatically insert a command button into a worksheet that is
not the active worksheet. I dont care about placement, size , just that the command button is on worksheet "main" and the command button is "emp1". thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Something like this
Sub Test() InsertButton Workbooks("Book2").Sheets(1), 0, 0, 200, 100, "test", "test", "test" End Sub Sub InsertButton(shName As Worksheet, _ Top As Double, Left As Double, Width As Double, Height As Double, _ Action As String, Caption As String, Name As String) Dim bInsert As Object 'add the control button Set bInsert = shName.Buttons.Add(Left, Top, Width, Height) bInsert.OnAction = Action bInsert.Characters.Text = Caption bInsert.Name = Name End Sub Robin Hammond www.enhanceddatasystems.com "Qaspec" wrote in message ... i want to programatically insert a command button into a worksheet that is not the active worksheet. I dont care about placement, size , just that the command button is on worksheet "main" and the command button is "emp1". thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Insert select button on excel worksheet to auto transfer data. | Excel Worksheet Functions | |||
How to insert a macro button in a worksheet | Excel Discussion (Misc queries) | |||
How do I insert a drop down list button from an excel worksheet? | Excel Worksheet Functions | |||
INSERT A PRINT BUTTON ON A WORKSHEET | Excel Discussion (Misc queries) | |||
programmatically insert multiple blank rows in worksheet | Excel Programming |