how to apply particular FORMAT of date by using eval?

前端 未结 6 769
孤街浪徒
孤街浪徒 2021-01-03 20:45

I have used following code :

 \'> 
         


        
6条回答
  •  感动是毒
    2021-01-03 21:24

    I suppose you have a DateTime variable named MyDate:

    DateTime MyDate;
    

    If you want juste the date part:

    MyDate.Value.ToString("d");
    

    With the day:

    MyDate.Value.ToString("D");
    

    Here is a usefull doc PDF Doc

提交回复
热议问题