VBscript string parsing problem

Results 1 to 2 of 2

Thread: VBscript string parsing problem

  1. #1
    Join Date
    Dec 1969

    Default VBscript string parsing problem

    I have a string that looks like this /root/catalog/ I want to return it to look like this rootcatalog so basically I need to parse out the /&#039s I know you can use Grep in Perl but how do you do this in VBscript

  2. #2
    Join Date
    Dec 1969

    Default RE: VBscript string parsing problem

    There is a replace function. It returns a string and takes three parameters:<BR><BR>newString = Replace(oldString,SearchFor,ReplaceWith)<BR><BR>So , if you want to get rid of all "/" in a string named strPath, you could do:<BR><BR>strPath = Replace(strPath,"/","")<BR><BR>See http://msdn.microsoft.com/scripting/default.htm?/scripting/vbscript/doc/vsfctReplace.htm for a technical explanation of the Replace function.<BR><BR>Have a great day!

Posting Permissions

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