SQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsDatabaseSQL Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old September 26th, 2000, 12:56 PM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 22
PARSE COMMA SEPERATED TEXT

<i><b>Originally posted by : RAJ (rajkedda@hotmail.com)</b></i><br />How do I separate a comma separated text into an array.<br />for example:<br />states=st1,st2,st3,st4,st5 <br /> to<br />states[1] = st1<br />states[2] = st2<br />...<br />states[i] =sti <br /><br />I would like to do this in ASP as the variable is also an asp variable<br /><br />Thanks<br />

Reply With Quote
  #2  
Old November 9th, 2000, 10:49 AM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 22
<i><b>Originally posted by : Akhilesh Kumar (akhilesh-kumar@usa.net)</b></i><br /><br /><br /><br />------------<br />RAJ at 9/26/2000 10:56:18 AM<br /><br />How do I separate a comma separated text into an array.<br />for example:<br />states=st1,st2,st3,st4,st5 <br /> to<br />states[1] = st1<br />states[2] = st2<br />...<br />states[i] =sti <br /><br />I would like to do this in ASP as the variable is also an asp variable<br /><br />Thanks<br /><br />hi Raj,<br /> It's a very simple thing to separate a comma<br />separated string.There is one function in vbscript<br />states = Split(string,",")<br />This function takes two input parameters.<br />first parameter is the comma separated string.<br />you don't have to do anything else the string will<br />be automatically split and stored in to an array.<br />But mind it you substring i.e str1,str2.. should not contain an array , otherwise you won't be able to achieve your objective.<br />In that case you can replace "," by some other<br />symbol and again replace it back after you get an array of splitted substrings.<br /> thanks .<br />Reply soon if your problem is solved.

Reply With Quote
Reply

Viewing: ASP Free ForumsDatabaseSQL Development > PARSE COMMA SEPERATED TEXT


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT