Custom Content Type Question
-
I'm building a custom content type in vs and I have a field that is a date. I am using field type of "DateTime", but how can I have only the date and not the time?
-
I'm building a custom content type in vs and I have a field that is a date. I am using field type of "DateTime", but how can I have only the date and not the time?
Set the FieldType to DateTime and the Format to "DateOnly":
Hope I could help you.
------------------------------ Author of Primary ROleplaying SysTem How do I take my coffee? Black as midnight on a moonless night. War doesn't determine who's right. War determines who's left.
-
Set the FieldType to DateTime and the Format to "DateOnly":
Hope I could help you.
------------------------------ Author of Primary ROleplaying SysTem How do I take my coffee? Black as midnight on a moonless night. War doesn't determine who's right. War determines who's left.
Thanks. I finally found on msdn the page that tells you what each attribute is in the tag and completely forgot to update this post.
-
I'm building a custom content type in vs and I have a field that is a date. I am using field type of "DateTime", but how can I have only the date and not the time?
i thing you are using visualwebpart in coding just give this.DateTimeControl1.SelectedDate.ToShortDateString() (don't give this.DateTimeControl1.SelectedDate.ToString() it show's time also)
-
i thing you are using visualwebpart in coding just give this.DateTimeControl1.SelectedDate.ToShortDateString() (don't give this.DateTimeControl1.SelectedDate.ToString() it show's time also)
No, I'm sending a string to a HTML control because I just want to display text on the screen.