ipbr21054
Well-known Member
- Joined
- Nov 16, 2010
- Messages
- 5,832
- Office Version
- 2007
- Platform
- Windows
Hi,
I have the following working code in use.
I then recorded a macro to format a range to TEXT of which is shown below,
When i add this line of code to the Activate code i am told not supported.
My goal is when the worksheet is opened the range will always be TEXT format.
Can you please advise.
I have the following working code in use.
Code:
Private Sub Worksheet_Activate() Range("A3") = UCase(Format(Now, "mmmm"))
Range("D3") = Year(Now)
Range("A1:E3").HorizontalAlignment = xlCenter
Range("A1:E3").VerticalAlignment = xlCenter
Range("A1:E30, D31:E31, B35:C37, E35:E37 ").Borders.LineStyle = xlContinuous
Range("A5").Select
End Sub
I then recorded a macro to format a range to TEXT of which is shown below,
Code:
Range("A5:A30").Selection.NumberFormat = "@"
When i add this line of code to the Activate code i am told not supported.
My goal is when the worksheet is opened the range will always be TEXT format.
Can you please advise.