stevieinselby
New Member
- Joined
- Nov 12, 2015
- Messages
- 27
Runtime error 1004 - method 'Range' of object '_Worksheet' failed
This seems to be a very common error message, but none of the other problems that people have been having with it seem to have the same cause as mine...
In the code for one of my worksheets I have:
When I double-click on Y13 in that worksheet, instead of bringing up the user form like it did a couple of weeks ago when I set it up, it now brings up the dreaded 1004, and when I debug, it highlights "UserForm.Show".
UserForm is all set up under Forms, and I can't figure out why it isn't running, especially as the bit it has highlighted refers to neither Range nor Worksheet. Any suggestions?
This seems to be a very common error message, but none of the other problems that people have been having with it seem to have the same cause as mine...
In the code for one of my worksheets I have:
Code:
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
If Target(1, 1).Address = "$Y$13" Then
Cancel = True
UserForm.Show
End If
End Sub
When I double-click on Y13 in that worksheet, instead of bringing up the user form like it did a couple of weeks ago when I set it up, it now brings up the dreaded 1004, and when I debug, it highlights "UserForm.Show".
UserForm is all set up under Forms, and I can't figure out why it isn't running, especially as the bit it has highlighted refers to neither Range nor Worksheet. Any suggestions?