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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

String manipulation 1

Status
Not open for further replies.

xscape

Programmer
Apr 18, 2001
144
GB
Hi!

Just a quick question...

Please can you tell me the operator/function I can use to slice a string down into a certain number of characters!

eg If I only want to display two characters of the word hello so it comes out he. What do I use to do that?

Thanks a lot for your help!! :)
 
Left(string,length)

ex:
Dim myStr
myStr = "hello"
Response.write Left(myStr,2)

Check out the documentation for all the string functions at

there's also a Right, and an Instr

HTH - leo

------------
Leo Mendoza
lmendoza@garbersoft.net
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top