Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > .NET > Other .NET > .NET Web Services
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
.NET Web Services Discussions about .NET XML Web Service technologies including ASMX files, WSDL and SOAP.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the .NET Web Services section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old December 7th, 2004, 02:46 PM
Registered User
 
Join Date: Dec 2004
Location: chennai, tamilnadu, India.
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to bind date field in a datalist

i am using a datalist control, i am binding the date column from the database. i am getting the time also binded in the list, i want only the date to be bunded in that list. how to do this???...

Reply With Quote
  #2 (permalink)  
Old December 15th, 2004, 11:56 AM
planoie's Avatar
Friend of Wrox
Points: 16,481, Level: 55
Points: 16,481, Level: 55 Points: 16,481, Level: 55 Points: 16,481, Level: 55
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2003
Location: Clifton Park, New York, USA.
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

For a bound column, you can specify the "dataformatstring" attribute. In there you can put the exact date format you want:

<asp:boundcolumn datafield="datefield" dataformatstring="MMM dd yyyy" />
Reply With Quote
  #3 (permalink)  
Old January 19th, 2005, 12:19 AM
Registered User
 
Join Date: Jan 2005
Location: , , India.
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

if you are using a dynamically generated bound column, put the format as :
bndColumn.DataFormatString = "{0:MMM dd yyyy}"
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
bind recordset to field ibgreen SQL Language 0 October 24th, 2006 12:48 PM
Bind records from the table to a datalist control macupryk General .NET 1 October 13th, 2004 11:59 AM
How to bind data to a dropdown in a datalist thats broushly ASP.NET 1.0 and 1.1 Basics 1 April 28th, 2004 01:52 PM
How to bind unbound field ? cjordan BOOK: Professional Crystal Reports for VS.NET 1 January 23rd, 2004 01:34 PM
bind 2 tables in a datalist life_s Ng ASP.NET 1.0 and 1.1 Basics 4 December 19th, 2003 04:37 AM



All times are GMT -4. The time now is 06:20 AM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.