JeffGrant
Well-known Member
- Joined
- Apr 7, 2021
- Messages
- 558
- Office Version
- 365
- Platform
- Windows
Hi All,
I have a strange one. With this code, if I change sheet1.cells(4,15).value to sheet1.range("O4").value i get runtime 1004 error.
However, i use the range method in other modules and even other procedures in the same module without any errors at. In fact this is the only time that I am being forced to use the cells method. I use the range method everywhere else.
I would appreciate any suggestion as to why this one is so weird.
Thanks in advance
I have a strange one. With this code, if I change sheet1.cells(4,15).value to sheet1.range("O4").value i get runtime 1004 error.
However, i use the range method in other modules and even other procedures in the same module without any errors at. In fact this is the only time that I am being forced to use the cells method. I use the range method everywhere else.
I would appreciate any suggestion as to why this one is so weird.
Thanks in advance
VBA Code:
If Sheet1.Cells(4, 15).Value <= 3 And MonitorOnly = "Yes" Then
frmSelections31.Show
ElseIf Sheet1.Cells(4, 15).Value <= 3 Then
frmSelections3.Show
ElseIf Sheet1.Cells(4, 15).Value <= 4 And MonitorOnly = "Yes" Then
frmSelections41.Show
ElseIf Sheet1.Cells(4, 15).Value = 4 Then
frmSelections4.Show
ElseIf Sheet1.Cells(4, 15).Value <= 5 And MonitorOnly = "Yes" Then
frmSelections51.Show
Else:
frmSelections5.Show
End If