Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Senior Coder angst's Avatar
    Join Date
    Apr 2004
    Location
    Toronto, Ontario
    Posts
    2,114
    Thanks
    15
    Thanked 122 Times in 122 Posts

    how can i replace quotes in a string?

    Hello,
    I need to be able to replace quotes in a string i'm working with,

    my code:

    myString = objTS.ReadLine
    myString = replace(myString, char(34), "")
    myArray = Split(mystring, ",")

    i know i can't use 3 quotes in a row,
    and char(34) isn't working either,

    using the above code i get this error:
    Type mismatch: '[undefined]'

    so my question is how can this be done?

    thanks in advance for your time!
    ken

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You need FOUR quotes to make it work.

    myString = replace(myString,"""", "")
    Check out the Forum Search. It's the short path to getting great results from this forum.


  •  

    Posting Permissions

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