I’m trying to add DateTime (7/30/2011) columns dynamically in a DataGrid. I will upload a screenshot of my grid which I made manually. I want to make a range combobox. So if the user chooses 2 weeks, then the grid adds day by day columns.

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can do something like this
This could be called on the Combobox
OnSelectionChanged()You can also use a DataTemplate to properly display columns:
No just adjust your StringFormat for your needs:
Basic is
Binding="{Binding date, StringFormat={}{0:dd/MM/yyyy}}"