c# - Datetime Format to Date -


how convert this?

public datetime date { get; set; } 

i need display date.

please 1 convert date only

i need display date.

the datetime structure has numerous ways accomplish this, commonly .toshortdatestring() , .tolongdatestring():

var displaydate = date.toshortdatestring(); 

for further customizations, can supply a formatting string the .tostring() method.


Comments

Popular posts from this blog

java - WrongTypeOfReturnValue exception thrown when unit testing using mockito -

php - Magento - Deleted Base url key -

android - How to disable Button if EditText is empty ? -