Hello,
Trying to write some macros, the first one clears a range when clicking a button.
The other one is supposed to scan a cel range for parsing purposes.
I'm stuck on both, getting "Compile Error: Invalid Character" and don't understand why. I highlighted the problematic rows below in red.
Any assistance would be greatly appreciated.
---------------------------------------------------------------------------------------------
Sub Clear_NOTAM()
Dim NOTAMSheet As Worksheet
Dim LastNOTAMRow As Integer
Set NOTAMSheet = Worksheets("Copy Paste NOTAM")
LastNOTAMRow = NOTAMSheet.UsedRange.Rows(NOTAMSheet.UsedRange.Rows.Count).Row
Worksheets("Copy Paste NOTAM").Range("A1:B" & str(LastNOTAMRow)).Value = ""
End Sub
---------------------------------------------------------------------------------------------
Sub Reformat_NOTAM()
Dim NOTAMSheet As Worksheet
Dim LastNOTAMRow As Integer
Dim NOTAMInputRange As Range
Dim RowIdx As Integer
Dim ColIdx As Integer
Dim CellValue As String
Set NOTAMSheet = Worksheets("Copy Paste NOTAM")
LastNOTAMRow = NOTAMSheet.UsedRange.Rows(NOTAMSheet.UsedRange.Rows.Count).Row 'Find last row
for RowIdx = 1 to LastNOTAMRow
End Sub
Trying to write some macros, the first one clears a range when clicking a button.
The other one is supposed to scan a cel range for parsing purposes.
I'm stuck on both, getting "Compile Error: Invalid Character" and don't understand why. I highlighted the problematic rows below in red.
Any assistance would be greatly appreciated.
---------------------------------------------------------------------------------------------
Sub Clear_NOTAM()
Dim NOTAMSheet As Worksheet
Dim LastNOTAMRow As Integer
Set NOTAMSheet = Worksheets("Copy Paste NOTAM")
LastNOTAMRow = NOTAMSheet.UsedRange.Rows(NOTAMSheet.UsedRange.Rows.Count).Row
Worksheets("Copy Paste NOTAM").Range("A1:B" & str(LastNOTAMRow)).Value = ""
End Sub
---------------------------------------------------------------------------------------------
Sub Reformat_NOTAM()
Dim NOTAMSheet As Worksheet
Dim LastNOTAMRow As Integer
Dim NOTAMInputRange As Range
Dim RowIdx As Integer
Dim ColIdx As Integer
Dim CellValue As String
Set NOTAMSheet = Worksheets("Copy Paste NOTAM")
LastNOTAMRow = NOTAMSheet.UsedRange.Rows(NOTAMSheet.UsedRange.Rows.Count).Row 'Find last row
for RowIdx = 1 to LastNOTAMRow
End Sub