Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I compare strings? 1

Status
Not open for further replies.

cindyray

Programmer
Jun 12, 2001
24
0
0
US
I used a maskeditbox to ensure the entries made to an Access database were made correctly, but now I need to do run a labels based on the date. Is there an easy way to handle this?
 
Is StrComp able to find multiple matches and ones that are greater than the date I'm searching?
 
You can use also InStr(or InStrRev) to find the matches wanted, another way would be to use regular expresion from the vbscript runtime library(the regexp object).

It has a rather strange sintax but is the fastest and versatile of all.

Anyway if you will spend some time learning Regular Exppresion you will find for it many usages.

Hope this helps s-)

Blessed is he who in the name of justice and good will, shepards the week through the valley of darkness...
 
I ended up doing a type conversion from string to date during my search and this worked much better than the StrComp and InStr...mainly because it ended up being so much simpler and easier to code. Thanks for the help.

Cindy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top