Runtime error 13 type mismatch

cicada

Board Regular
Joined
Jan 10, 2010
Messages
79
Hi all am trying to run the following,

Private Sub Worksheet_Calculate()
With ThisWorkbook.Sheets("HILO_TURBO")
If Len(.Range("J7").Value) = 6 And (.Range("E40").Value > 0) Then
.Parent.Sheets("sheet1").Range("D3:D6").Value = .Range("J19:J22").Value
End If
End With
'...
End Sub

and am getting a runtime error type mismatch it is showing up on the If LEN line. this is running with a dde link. Any help appreciated.

Thanks
Dan
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.

Forum statistics

Threads
1,225,502
Messages
6,185,350
Members
453,287
Latest member
Emeister

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top