SPONSORS:






User Tag List

Results 1 to 4 of 4
  1. #1
    Junior Member
    Join Date
    Jan 2002
    Location
    Newark, CA, USA
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How can I delete invalid char such as \"\\n\" or \"\\r\"...

    Hi,

    I am tring to verify text.
    It gets newline char as well..
    This cannot be recornized by my silk set.

    Anybody knows how I can avoid this problem??
    Thank you!

    ------------------

  2. #2
    Senior Member
    Join Date
    Jul 2001
    Posts
    147
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How can I delete invalid char such as \"\\n\" or \"\\r\"...

    I'm assuming that you want to ignore "\n" and "\r". If so try the function StrTran.

    Example:

    String s = "Line 1 \n Line 2 \n"
    Print (StrTran (s, "\n", ""))

    Prints: Line 1 Line 2



    ------------------
    Who Tests The Tester...
    Who Tests The Tester...

  3. #3
    Senior Member
    Join Date
    Nov 1999
    Location
    Eagle, ID,USA
    Posts
    1,035
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How can I delete invalid char such as \"\\n\" or \"\\r\"...

    I do the following to get rid of new line characters:

    sDialogResultMessage = Stuff(sDialogResultMessage,13,2,"");

    ------------------
    Have you ever noticed? Anybody going slower than you is an idiot, and anyone going faster than you is a maniac.

  4. #4
    Junior Member
    Join Date
    Jan 2002
    Location
    Newark, CA, USA
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How can I delete invalid char such as \"\\n\" or \"\\r\"...

    I got it!!!!

    Thanks guys!!!

    The problem is that the string contains "|" looking char which is translate to "\n".
    So I have used the Stuff () function to take out. Now it works!!!

    Thanks again!

    ------------------

 

 

Posting Permissions

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

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 02:24 AM.

Copyright BetaSoft Inc.