Jump to content
Mike Torrettinni

Micro optimization: IN vs OR vs CASE

Recommended Posts

2 hours ago, pmcgee said:

I can't seem to get rid of this extra image ...

If it helps: when you add images they are listed below the post as Uploaded images and you can delete them by clicking on delete icon, if you can't delete them within the post:

 

image.png.52e26ddb48cae5fafd2d471a438722dc.png

  • Thanks 1

Share this post


Link to post

@Pat Foley and @pmcgee thanks for the solution using a Set, but I can't really use them because the list of controls exceeds 256 items.  But very good timings, will see if I can use the logic for some smaller pool of data. I have many that are definitely less than 100 count.

Share this post


Link to post

You missed the name of program interSector.dir  It calls the chips intersector routine look at the disassembly.

The only documentation I have found is this. VP2INTERSECT
 

I done a lot of spreadsheets using just formulas over the years...

 

Excel
Range("A1:A10").Select                            'Selects cells A1 to A10.
Range(Range("A1"), Range("A10")).Select           'Selects cells A1 to A10.
Range("A1, A10").Select                           'Selects cells A1 and A10.
Union(Range("A1"), Range("A10")).Select           'Selects cells A1 and A10.
Range("A1:A5 A5:A10").Select                      'Selects cell A5.
Intersect(Range("A1:A5"), Range("A5:A10")).Select 'Selects cell A5. 

Delphi's DB and graphics have similar functions. TList<T> has range! 

 

Pat

Edited by Pat Foley
add details

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×