I have a dropdownlist that display DateTime object in default format.
I want that visible date is in format "ddd dd/MM/yyyy HH:mm" like : Mon 13/08/2013 21:30
Using this code :
ddl_dat.DataTextFormatString="{0:dd/MM/yyyy}";
it work but show me only : 13/08/2013
Using instead
ddl_dat.DataTextFormatString="{ddd 0:dd/MM/yyyy HH:mm}";
I have a FormatException
试试这个:
ddl_dat.DataTextFormatString="{0: ddd d/MM/yyyy HH:mm}";
尝试这个,
<asp:DropDownList id="yourList" runat="server" dataTextFormatString="{0: ddd d/MM/yyyy HH:mm}"/>
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.