LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Johnny Meredith
 
Posts: n/a
Default Strange (?) Evaluate Method Behavior

Hi all,

I looked through the posting, but could not find this exact topic
discussed:

Assume I have defined a 2 dynamic ranges "MyDynamicRange1" &
"MyDynamicRange2". Both of these ranges are parallel to each other and
the same length. If there is no data in the range (which is a
possibility), then the ranges won't exist. When there is data in the
range, the following works as expected:

With Application
x = .Evauate("=SUMIF(MyDynamicRange1,'foo',MyDynamicRa nge2)")
End With

So far so good. If either of the ranges has no data, the wierdness
begins. Take a look at the following code:

Dim x as Variant
'Stuff here
With Application
Select Case strVar
Case "foo"
x = _
.Evauate("=SUMIF(MyDynamicRange1,'foo',MyDynamicRa nge2)")
Case "foo2"
x = _
.Evauate("=SUMIF(MyDynamicRange1,'foo2',MyDynamicR ange2)")
 
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
Strange paste selection behavior 1scant Excel Discussion (Misc queries) 1 March 2nd 06 09:58 PM
Strange behavior in INDEX(..., MIN(...)) - array formula vezerid Excel Discussion (Misc queries) 2 February 21st 06 11:56 AM
Excel Mac OS X - Strange Behavior BrianP Excel Discussion (Misc queries) 0 January 1st 06 08:07 AM
Questions about Strange ReCalc Behavior LawrenceHG Excel Discussion (Misc queries) 2 December 5th 05 12:53 AM
Strange behavior w/ Text, Button, & Check Boxes kswinth Excel Discussion (Misc queries) 0 June 26th 05 04:49 PM


All times are GMT +1. The time now is 02:49 AM.

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"