Datatable.Select and datetime type

  • Thread starter Thread starter MichalR
  • Start date Start date
M

MichalR

Hi,

I'm using this when selecting some rows (VB.NET):

Rows=Table.Select('date_column>=#" & Format(MyDate,"MM/dd/yy") & "#')

Is it really the only way to be locale independent when using filter
expressions? I cannot find any method converting datetime type into
"universal string date".

Thanks in advance for any suggestions.
Michal
 
Hi,

MichalR said:
Hi,

I'm using this when selecting some rows (VB.NET):

Rows=Table.Select('date_column>=#" & Format(MyDate,"MM/dd/yy") & "#')

Is it really the only way to be locale independent when using filter
expressions? I cannot find any method converting datetime type into
"universal string date".

Use CultureInfo.InvariantCulture, like
data.ToString(CultureInfo.InvariantCulture)
 
Back
Top