scorpid18
11-18-2015, 04:18 AM
Hi there! I've got a problem with worksheet_change :crying:
The purpose of my macro is, if the target is $C$5 at sheet("unit performance"), then the macro should select range("C5:E5") (a merged cell) in another worksheet, but the macro keep on refusing to do so. What is the problem?
here's the code I've made :
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$C$5" Then
Sheets("RM performance").Activate
Range("C5:E5").Select 'this is where the macro stuck (run time error '1004' - select method of range class failed)
any suggestion will be appreciated. Sorry for my bad english also. Thanks before :hi:
The purpose of my macro is, if the target is $C$5 at sheet("unit performance"), then the macro should select range("C5:E5") (a merged cell) in another worksheet, but the macro keep on refusing to do so. What is the problem?
here's the code I've made :
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$C$5" Then
Sheets("RM performance").Activate
Range("C5:E5").Select 'this is where the macro stuck (run time error '1004' - select method of range class failed)
any suggestion will be appreciated. Sorry for my bad english also. Thanks before :hi: