View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Bernie Deitrick Bernie Deitrick is offline
external usenet poster
 
Posts: 5,441
Default Worksheet change macro for paste special

Phil,

Yes, you can have only one, but it can be complex:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 1 Then Goto Column1
If Target.Column = 2 Then Goto Column2
If Target.Column = 4 Then Goto Column4
Exit Sub
Column1:
'Code for column 1
Exit Sub
Column2:
'Code for column 2
Exit Sub
Column4:
'Code for column 4
Exit Sub

End Sub


--
HTH,
Bernie
MS Excel MVP


"Phil" wrote in message
...
That is absolutely brilliant, Bernie!

Does the job a treat. many thanks for that.

One last queation - is it true I can only have one On Worksheet change
macro per sheet? I heard somewhere that was the case, not dure if it's
right.

Thanks again and best regards,

Phil