ASP Hosting sale!
Double disk space and transfer for FREE!
Limited time offer! Act Now!

aspdev | articles | tutorials | forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Get substring in ASP

 
Post new topic   Reply to topic    ASPdev.org Forum Index -> ASP programming
View previous topic :: View next topic  
Author Message
jon



Joined: 01 Oct 2004
Posts: 40

PostPosted: Thu Oct 28, 2004 1:20 pm    Post subject: Get substring in ASP Reply with quote

Hey all,

I need to extract a sub-string from a string, starting from the 5th character up to the 10th. Is there a simple APS function to do this, maybe substring or something like that?



Thanks,

Jon
Back to top
View user's profile Send private message
administrator
Site Admin


Joined: 01 Oct 2004
Posts: 183

PostPosted: Thu Oct 28, 2004 3:06 pm    Post subject: Reply with quote

To get a sub-string in ASP use the Mid VBScript function.
In your case use:

Code:

sSubString = Mid(sString, 5, 5)





Cheers
_________________
Peter
ASP & ASP.NET Articles and Tutorials
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    ASPdev.org Forum Index -> ASP programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2002 phpBB Group

SQL Tutorial