LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #13   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,202
Default Best/Easiest way to search/find in a string

Norman meant that the dictum is to always explicitly state the method of
comparison within the instr function command rather than depend on any
default/global setting. He used the term text comparision to mean how
the
comparison is to be performed (binary or text) rather than that the
vbTextCompare be used as you appeared to interpret his suggestion. Futher
he envisioned this as a guiding principle in general across all functions
where appropriate - an Axiom


An admirably clear exposition of my intent!


Whoops!!! Sorry, I completely missed what you were saying. Yes, explicitly
specifying values instead of relying on defaults would be a good practice to
get into... and for object properties I always do that; but I am a long time
BASIC and VB user (started programming in BASIC back in 1981), so some "bad"
habits have become totally ingrained over the years. Relying on the default
start position of 1 and the default text comparison method of "case
sensitive" for the InStr function is one of those bad habits... after nearly
30 years of not specifying them, I probably will never remember to do so in
the "heat" of a programming session.

Rick

 
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
Find specific info using search string using VBA laavista Excel Discussion (Misc queries) 5 May 20th 09 07:59 PM
Easiest way to find differences between Rows? Jonathan Excel Discussion (Misc queries) 3 February 20th 09 08:51 PM
Search/Match/Find ANY part of string to ANY part of Cell Value TWhizTom Excel Worksheet Functions 0 July 21st 08 08:16 PM
FIND / SEARCH text compare cell to string in 3rd cell nastech Excel Discussion (Misc queries) 0 October 29th 07 02:51 AM
search a string withing a string : find / search hangs itarnak[_9_] Excel Programming 4 October 24th 05 03:19 PM


All times are GMT +1. The time now is 07:18 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"