I would like to store the color resource property on a SQL database like I am doing with the resource Id and name, but I am wondering what data type should I use on the columns definition of the table in SQL. Could anyone help?
Thanks,
Rafael
3 Answers, 1 is accepted
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 26 Jan 2016, 12:34 PM
Hello Rafael,
Thank you for writing.
You can use this column type which is suitable for your case to store resource's color. Then, when data binding RadScheduler, you can use SchedulerMapping which is responsible for mapping a single property from the data source to a property, which allows you to specify convert callback methods in order to convert values to and from the data source if needed. Additional information is available on the following link: http://docs.telerik.com/devtools/winforms/scheduler/data-binding/scheduler-mapping
I hope this information helps. Should you have further questions I would be glad to help.
Regards,
Dess
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Thanks for your help. One question when you say "this column type" which one do you are talking about? Can I use a direct mapping with the color property or do I have to do a convertion method?
Thank you very much for your help!
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 28 Jan 2016, 03:01 PM
Hello Rafael,
Thank you for writing back.
There is no specific column type that is the most appropriate for storing Color values. That is why you can store the colors as string values in your database (e.g. "red", "green", "blue"). In this case, it would be necessary to use the SchedulerMapping approach described in my previous post where you should convert the stored string value to Color and vice versa.
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Dess
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items