Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 101
Default evaluate error

Sub dd()
MsgBox
Application.Evaluate("=ROUND(C5*H5*G5*IF(B15=""12. 7mm"",0.774,1.101)-IF(
C5<3,0,H5*IF(B15=""12.7mm"",0.774,1.101)*(SUMPRODU CT((ROW(INDIRECT(""1:"
"&INT((C5-1)/2)))*K15)*2)-IF(MOD(C5,2),K15*INT(C5/2),0))),0)")
End Sub

this function is not working.
but the function is work well in worksheet.





*** Sent via Developersdex http://www.developersdex.com ***
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,600
Default evaluate error

It was a bit fiddly to reconstruct but I get Cell formula and Evaluate
return same for me. IOW it seems to work fine.

Regards,
Peter T

"x taol" wrote in message
...
Sub dd()
MsgBox
Application.Evaluate("=ROUND(C5*H5*G5*IF(B15=""12. 7mm"",0.774,1.101)-IF(
C5<3,0,H5*IF(B15=""12.7mm"",0.774,1.101)*(SUMPRODU CT((ROW(INDIRECT(""1:"
"&INT((C5-1)/2)))*K15)*2)-IF(MOD(C5,2),K15*INT(C5/2),0))),0)")
End Sub

this function is not working.
but the function is work well in worksheet.





*** Sent via Developersdex http://www.developersdex.com ***



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,726
Default evaluate error

It worked fine for me (albeit in limited testing), it gave the same result
as the worksheet.

I restructured it to make it more readable

MsgBox
Application.Evaluate("=ROUND(C5*H5*G5*IF(B15=""12. 7mm"",0.774,1.101)-" & _
"IF(C5<3,0,H5*IF(B15=""12.7mm"",0.774,1.101)*" & _
"(SUMPRODUCT((ROW(INDIRECT(""1:""&INT((C5-1)/2)))*K15)*2)-" & _
"IF(MOD(C5,2),K15*INT(C5/2),0))),0)")


--
---
HTH

Bob

(change the xxxx to gmail if mailing direct)


"x taol" wrote in message
...
Sub dd()
MsgBox
Application.Evaluate("=ROUND(C5*H5*G5*IF(B15=""12. 7mm"",0.774,1.101)-IF(
C5<3,0,H5*IF(B15=""12.7mm"",0.774,1.101)*(SUMPRODU CT((ROW(INDIRECT(""1:"
"&INT((C5-1)/2)))*K15)*2)-IF(MOD(C5,2),K15*INT(C5/2),0))),0)")
End Sub

this function is not working.
but the function is work well in worksheet.





*** Sent via Developersdex http://www.developersdex.com ***



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
evaluate afdmello Excel Worksheet Functions 3 May 16th 10 09:11 PM
Error 2015 with Application.Evaluate Jeff Excel Programming 3 June 6th 06 04:00 PM
HOW to Evaluate a range with IF ? dancab Excel Discussion (Misc queries) 3 September 1st 05 05:08 PM
Evaluate error when using 2 crazybass2 Excel Programming 2 May 13th 05 03:40 PM
evaluate HYPERLINK() rabbit ribbit Excel Worksheet Functions 1 March 2nd 05 12:09 PM


All times are GMT +1. The time now is 06:59 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"