trim return caracter

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Séverine Donnay

    trim return caracter

    Hi,

    I make a csv file with values from data base fields . If my value contains a
    carriage return caracter at the end, a new line is created in my csv file. I
    tried to replace chr(13) caracter by an empty caracter but it doesn't work,
    my code is :
    Replace(Trim(el ement.value), chr(13),"")

    Do you have any idea to resolve my problem ?
    Thanks.

    Severine


  • Ray Costanzo [MVP]

    #2
    Re: trim return caracter

    Try replacing vbCrLf instead of Chr(13).

    Replace(Trim(el ement.value), vbCrLf,"")

    Ray at work



    "Séverine Donnay" <sdonnay@winooz .net> wrote in message
    news:DVukd.2468 2$km5.1275425@n ews20.bellgloba l.com...[color=blue]
    > Hi,
    >
    > I make a csv file with values from data base fields . If my value contains
    > a
    > carriage return caracter at the end, a new line is created in my csv file.
    > I
    > tried to replace chr(13) caracter by an empty caracter but it doesn't
    > work,
    > my code is :
    > Replace(Trim(el ement.value), chr(13),"")
    >
    > Do you have any idea to resolve my problem ?
    > Thanks.
    >
    > Severine
    >
    >[/color]


    Comment

    Working...