Posted 6 January 2024, 11:30 pm EST
Can I access inputdatepicker calendar properties?
I needed to change the width of the dropdown calendar
Thanks
JP
Forums Home / ComponentOne / WinForms Edition
Posted by: comercial on 6 January 2024, 11:30 pm EST
Posted 6 January 2024, 11:30 pm EST
Can I access inputdatepicker calendar properties?
I needed to change the width of the dropdown calendar
Thanks
JP
Posted 7 January 2024, 9:50 pm EST
Hello,
There is no direct way to change the width of the drop-down calendar, but you can access it in the DropDown event of InputDatePicker as follows:
private async void InputDatePicker1_DropDown(object sender, EventArgs e)
{
await Task.Delay(5);
var calendar = Application.OpenForms[1].Controls[0];
calendar.Width += 100;
}
Posted 8 January 2024, 2:49 am EST
Uttkarsh, a workaround would save me a lot of problems.
We have to launch a new version of our software and its stuck because of this problem.
Regards
JB
Posted 8 January 2024, 7:27 pm EST
Hello,
The only workaround we could think of is to set StandardFormat to LongDate, but the Today date text at the bottom overflows while displaying LongDate in the “PT-pt” locale.
inputDatePicker1.StandardFormat = C1.Win.C1InputPanel.InputDateFormat.LongDate;
Refer to the attached sample. (see InputPanel48_DateTimePicker_Mod.zip)Posted 8 January 2024, 8:41 pm EST
But then the users would see the date value in the field as a long date right?
That cant be, because they have to change it often, even manually. And there´s a lot of date fields in our application.
I will be waiting for some updates from the developers. We really need this.
Thanks
JB
Posted 11 January 2024, 9:56 pm EST
Hello,
We have addressed your case in the previous ticket.
Kindly carry on the discussion related to this use case in that same thread to prevent any confusion.
Regards,
Uttkarsh