-
Solved: Creating a Button For A Workbook Macro
I'm trying to make a button on the workbook that will activate a macro. I tried using Excel help but I still cant figure it out. I want this button to go with the workbook so others may use it when I send them the file. When you press the button I want it to call "Main" which runs the code.
[VBA]Public Sub Main()
Application.ScreenUpdating = False
Dim rngStart As Range
Set rngStart = Selection
Sheets("Tables").Activate
' Sheets("Tables").Select
First_Shift_Sort
Flex_Shift_Sort
Second_Shift_Sort
SD_Sort
With rngStart
.Parent.Activate
.Select
End With
Application.ScreenUpdating = True
End Sub
[/VBA]
Thanks
Gary
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules