Hi
I'm looking to create a custom filter control to use on a popup container control. Essentially I want two calendars side by side where a user can select a start and end date, one from each calendar. I also want them to have the ability to select the start year without having to scroll through years of dates to find the date in a particular year. The standard windows forms date time picker has this functionality but I haven't found an infragistics calendar control with this functionality (so if you click on the month in the heading it drills to the months with the year on top then you can drill through the years) . I've tried the UltraMonthViewSingle control that comes close as it doesn't require drop down but cant see a way of displaying the year and drilling through them.
Any advice would be appreciated.
Cheers
Dave
Hi Dave,
We thank you for the feedback. I would like to point you to the following section of our website, which is created exactly with the idea that our customers can suggest features and new components not available in our toolkit:
http://ideas.infragistics.com
There are many benefits to submitting a product idea:
- Direct communication with our product management team regarding your product idea.
- Notifications whenever new information regarding your idea becomes available.
- Ability to vote on your favorite product ideas to let us know which ones are the most important to you. You will have ten votes for this and can change which ideas you are voting for at any time.
- Allow you to shape the future of our products by requesting new controls and products altogether.
- You and other developers can discuss existing product ideas with members of our Product Management team.
Thank you for using Infragistics components.
Sincerely,Tihomir TonevAssociate Software DeveloperInfragistics
Hi Mike
Thanks for the demo and taking time to look into this.
I've actually managed to create something that seems to be exactly what you suggested. I created a custom control with two month calendars and added the control to the popup container control. I also keep the date ranges in sync between the two month calendars as you have done by only showing the range of dates after the start date selected. If the user selects another start date then the start date range refills. If the user changes end date then the start date range changes to a max date of the end date selected.
Spooky how both solutions are so similar :)
Would be cool if at some point infragistics adds this type of calendar control (month calendar with no drop down). to their arsenal so can be as fully featured as the existing infragistics controls.
Hi Tihomir
Thanks for the suggestions. However the solution I was looking for was to not have to use a dropdown to have to select a date but have a display like the MonthCalendar in standard windows controls but it looks like infragistics don't have this type of control.
This seems like a fun and interesting challenge, so I went ahead and created a sample prototype. To keep it simple, I don't allow the user to type into the control. There is more to do here, I expect, but I think it works pretty well as is.
DateRange.zip
The second approach, with two MonthCalendars on a DropDown seems like it would be very neat.
But there would be a lot of coding involved, I think.
You might want to put in some labels to make it clearer what the calendars are for. Also, there's the question of whether you want the user to be allowed to type into the combo. And if so, you would need some kind of parsing logic to turn the user-entered string into a range of dates. Presumably using some kind of custom format like using a dash to separate the dates. You would want to handle the dropping down of the button so you can synchronize the calendars with the current date range. And then there is error-handling for when the parsing fails. It would be interesting to make this work, though. :)