brothertruffle880
asked on
Excel Macros - Help with navigation
I have a macro that bolds a cell and changes the size of the font. However, I would like the macro to position the cursor at cell A1 (the very top/beginning of my spreadsheet).
What command do I need to add to this macro.
Also, I didn't make any modifications to "shadow," "subscript," etc. Can I safely delete those lines from my macro?
Sub test()
' test Macro
Selection.Font.Bold = True
With Selection.Font
.Name = "Calibri"
.Size = 22
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ThemeColor = xlThemeColorLight1
.TintAndShade = 0
.ThemeFont = xlThemeFontNone
End With
End Sub
What command do I need to add to this macro.
Also, I didn't make any modifications to "shadow," "subscript," etc. Can I safely delete those lines from my macro?
Sub test()
' test Macro
Selection.Font.Bold = True
With Selection.Font
.Name = "Calibri"
.Size = 22
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ThemeColor = xlThemeColorLight1
.TintAndShade = 0
.ThemeFont = xlThemeFontNone
End With
End Sub
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
add these activewindow lines to the bottom of the code as well, right after (or before, doesn't matter) rspahitz's suggestion...
Range("A1").select
Activewindow.ScrollRow =1
ActiveWindow.ScrollColumn = 1
Open in new window
I dont know if that will 100% work, but it looks to be promising. Also you can delete the other fields.