function InStr(strSearch, charSearchFor)
/*
InStr(strSearch, charSearchFor) : Returns the first location a substring (SearchForStr)
was found in the string str. (If the character is not
found, -1 is returned.)
Requires use of:
Mid function
Len function
*/
{
for (i=0; i < Len(strSearch); i++)
{
if (charSearchFor == Mid(strSearch, i, 1))
{
return i;
}
}
return -1;
}
| file: /techref/language/asp/js/inStr.htm, 0KB, , updated: 2003/4/15 13:52, local time: 2008/11/23 10:50,
38.103.63.57:LOG IN
|
| ©2008 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions? Please DO link to this page! Digg it! <A HREF="http://techref.massmind.org/techref/language/asp/js/inStr.htm"> language asp js inStr</A> |
| Did you find what you needed? |
Welcome to massmind.org! |
|
.