![]() |
keep getting type mismatch error
I keep getting a "type mismatch" error for below. I know it has to be something simple that I'm missing. Can anyone help? If .Range("j2") < .Range("k1") Then ..Range("a4:i4") = .Range("a3:i3") ..Range("a4:i4").Value = .Range("a4:i4").Value ..Range("e4") = "PA" ..Range("e5") = Evaluate("f3*k1-j1") End If -- vbidiot ------------------------------------------------------------------------ vbidiot's Profile: http://www.excelforum.com/member.php...o&userid=31582 View this thread: http://www.excelforum.com/showthread...hreadid=512725 |
keep getting type mismatch error
works fine for me (no errors) - it may depend on what's in the cells you're
referencing. But the statement Range("A4:i4")=.Range("A3:I3") should really contain ".value" at the end of the range. or it won't work as expected. "vbidiot" wrote in message ... I keep getting a "type mismatch" error for below. I know it has to be something simple that I'm missing. Can anyone help? If .Range("j2") < .Range("k1") Then Range("a4:i4") = .Range("a3:i3") Range("a4:i4").Value = .Range("a4:i4").Value Range("e4") = "PA" Range("e5") = Evaluate("f3*k1-j1") End If -- vbidiot ------------------------------------------------------------------------ vbidiot's Profile: http://www.excelforum.com/member.php...o&userid=31582 View this thread: http://www.excelforum.com/showthread...hreadid=512725 |
keep getting type mismatch error
On what line exactly are you getting the error??
"vbidiot" wrote: I keep getting a "type mismatch" error for below. I know it has to be something simple that I'm missing. Can anyone help? If .Range("j2") < .Range("k1") Then .Range("a4:i4") = .Range("a3:i3") .Range("a4:i4").Value = .Range("a4:i4").Value .Range("e4") = "PA" .Range("e5") = Evaluate("f3*k1-j1") End If -- vbidiot ------------------------------------------------------------------------ vbidiot's Profile: http://www.excelforum.com/member.php...o&userid=31582 View this thread: http://www.excelforum.com/showthread...hreadid=512725 |
keep getting type mismatch error
Below is the line that gets the debug error. If .Range("j2") < .Range("k1") Then -- vbidiot ------------------------------------------------------------------------ vbidiot's Profile: http://www.excelforum.com/member.php...o&userid=31582 View this thread: http://www.excelforum.com/showthread...hreadid=512725 |
keep getting type mismatch error
Here's code before the line that debugs. Could that be a problem? ..Range("j1") = Evaluate("=f1*g1" + "f2*g2") ..Range("j2") = Evaluate("=j1\f3") ..Range("k1") = 10 If .Range("j2") < .Range("k1") Then ..Range("a4:i4").Value = .Range("a3:i3").Value ..Range("e4") = "PA" ..Range("f4") = Evaluate("f3*k1-j1") End If -- vbidiot ------------------------------------------------------------------------ vbidiot's Profile: http://www.excelforum.com/member.php...o&userid=31582 View this thread: http://www.excelforum.com/showthread...hreadid=512725 |
All times are GMT +1. The time now is 12:11 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com