Results 1 to 3 of 3
  1. #1
    Join Date
    Aug 2003
    Location
    London,UK
    Posts
    54

    Unanswered: removing first 11 characters in a string

    i have got a string called oldname which holds some information

    however i need to remove the first 11 characters from this string

    can it be done and how please.

    i have been looking on the nex and the closest that i can find is Left() which only uses the first 11 characters but i get hold of the rest

    thankx in advance

  2. #2
    Join Date
    Oct 2003
    Location
    Chicago
    Posts
    2

    use mid(STRING, STARTPOSITION, ENDPOSITION)

    Hi,

    Use the mid(STRING, STARTPOSITION, ENDPOSITION) function.

    In your case to remove the first 11 characters it would be:

    <%
    // If endposition attribute is not declared, will just read to the end...
    // ...of the string
    response.write mid(your_string, 12)
    %>

    Hope this helps!

  3. #3
    Join Date
    Feb 2002
    Location
    San Francisco, CA
    Posts
    441
    or left(string,length) or right(string,length)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •