Hi all,
Thank you in advance. I'm very new to VBA/macros and I think I have a relatively easy task to complete, but I can't seem to figure it out. I received a bunch of UTMs for salmon redds, but in the wrong format and need to use a batch converter to change them to Lat/Longs in order to import the data to GIS. The batch converter also requires values to be in the same cell. So, I'm trying to use a macro to add the missing info to the UTMs and format them in to single cells to match the converter's requirements. Ex: If, A8= 536371 & B8 = 4888161, it needs to be changed so that A8 = 10N 536371mE 4888161mN. All cells will have 10N ******mE ******mN. The macro that currently works is as follows, but it's only filling in the original cell values, instead of adding the the missing formatting to each *unique* value set...
Sub reddtest()
'
' reddtest Macro
'
' Keyboard Shortcut: Ctrl+r
'
ActiveCell.FormulaR1C1 = "10N 536165mE"
ActiveCell.Offset(0, 1).Range("A1").Select
ActiveCell.FormulaR1C1 = "4888137mN"
ActiveCell.Offset(0, -1).Range("A1").Select
ActiveCell.FormulaR1C1 = "10N 536165mE 4888137mN"
ActiveCell.Offset(1, 0).Range("A1").Select
End Sub
Thank you in advance. I'm very new to VBA/macros and I think I have a relatively easy task to complete, but I can't seem to figure it out. I received a bunch of UTMs for salmon redds, but in the wrong format and need to use a batch converter to change them to Lat/Longs in order to import the data to GIS. The batch converter also requires values to be in the same cell. So, I'm trying to use a macro to add the missing info to the UTMs and format them in to single cells to match the converter's requirements. Ex: If, A8= 536371 & B8 = 4888161, it needs to be changed so that A8 = 10N 536371mE 4888161mN. All cells will have 10N ******mE ******mN. The macro that currently works is as follows, but it's only filling in the original cell values, instead of adding the the missing formatting to each *unique* value set...
Sub reddtest()
'
' reddtest Macro
'
' Keyboard Shortcut: Ctrl+r
'
ActiveCell.FormulaR1C1 = "10N 536165mE"
ActiveCell.Offset(0, 1).Range("A1").Select
ActiveCell.FormulaR1C1 = "4888137mN"
ActiveCell.Offset(0, -1).Range("A1").Select
ActiveCell.FormulaR1C1 = "10N 536165mE 4888137mN"
ActiveCell.Offset(1, 0).Range("A1").Select
End Sub