Skip to main content

When i add a Calendar control on form and select a date in a control. Value is displayed as 10/16/2016 but when i save that into my datasource using create method it stores it as 2016-10-16. How do i fix this so that dates are stored as 10/16/2016 when stored in DB.

 

Thank You

 

Hi N @npokhrel,


 


I have done some testing and it seems to come down to the data type being used in your SmartObject. So I noticed that when you save a value from a calendar control to a Text property then the value will be saved as 2016-10-21 however if you save the value to a Date or Date and Time property then the value will be saved with the same formating as the calendar controls default formating which is 10/21/2016. This being the case please ensure that your data type (SmartObejct properties) are set to either Date or Date and Time inside of your SmartObejct in order to get the desired formating.


 


I have tested this on K2 SmartForms 4.6.11, please see the results in the screenshot below:


16610iD048023F185F7BC9.png


Kind Regards,


Raymond


 


Reply