Hi Folks,
Complete VBA Noob here. Been reading these forums for a long time. Finally found a topic I can't find anywhere.
I've got a number of frozen panes at the top of a spreadsheet referencing the active row of the same sheet.
I've used this code to transpose my active cells to the top.
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Range("A" & (ActiveCell.Row)).Copy Destination:=Range("A3")
Range("B" & (ActiveCell.Row)).Copy Destination:=Range("B3")
Range("C" & (ActiveCell.Row)).Copy Destination:=Range("C3")
End Sub
The problem I'm having is that Column C is calculated by a formula. I understand I have to use PasteSpecial to bring the value and not the formula, but I can't seem to make it work.
Help?
much thanks!
Complete VBA Noob here. Been reading these forums for a long time. Finally found a topic I can't find anywhere.
I've got a number of frozen panes at the top of a spreadsheet referencing the active row of the same sheet.
I've used this code to transpose my active cells to the top.
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Range("A" & (ActiveCell.Row)).Copy Destination:=Range("A3")
Range("B" & (ActiveCell.Row)).Copy Destination:=Range("B3")
Range("C" & (ActiveCell.Row)).Copy Destination:=Range("C3")
End Sub
The problem I'm having is that Column C is calculated by a formula. I understand I have to use PasteSpecial to bring the value and not the formula, but I can't seem to make it work.
Help?
much thanks!