Problem with date in dataset. Need help. Thanks.

S

Shapper

Hello,

In the [pubDate] field of a dataset the content in each row has the
format:
Fri, 20 May 2005 12:30:00 GMT

When I use:
<%# DataBinder.Eval(Container.DataItem, "pubDate", "{0:f}") %>

the content is not being recognized as a date.
Well, at least it is not formatted as a date. It just shows the text.

Why? How can I solve this?

Thanks,
Miguel
 
G

Guest

==><%# DataBinder.Eval(Container.DataItem, "pubDate", "{0:f}") %>
to :
<%# DataBinder.Eval(Container.DataItem, "pubDate", "{0:r}") %>
 
S

Shapper

Hello,

I tried that. It's still the same.
It shows the entire text.

I have no idea what is going on.

Can someone tell me what is wrong here?

Thanks,
Miguel

==><%# DataBinder.Eval(Container.DataItem, "pubDate", "{0:f}") %>
to :
<%# DataBinder.Eval(Container.DataItem, "pubDate", "{0:r}") %>

:

Hello,

In the [pubDate] field of a dataset the content in each row has the
format:
Fri, 20 May 2005 12:30:00 GMT

When I use:
<%# DataBinder.Eval(Container.DataItem, "pubDate", "{0:f}") %>

the content is not being recognized as a date.
Well, at least it is not formatted as a date. It just shows the text.

Why? How can I solve this?

Thanks,
Miguel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top