I search a useful function...

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • philip

    #1

    I search a useful function...

    When I write :
    DFim StarName as string= "Jean d'Armentieres"
    Dim Dt as datatable
    Dt=OneDataset.t ables(0)
    Dim rows() as datarow
    rows=dt.select ("artiste_name= '" & StarName & "'")

    I have obviously an error on the last line.
    Because the "'" of "Jean d'Armentieres" is bad interpreted.
    Is there a function who transform a string in a string interpretable in the
    kind of case ?

    Waiting, I use the function 'Replace' like this :
    rows=dt.select ("artiste_name= '" & replace(StarNam e,"'","''') & "'")

    But there is may be better, no ?

    Thanks by advance


Working...