Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 4 of 4 total
Thread Selecting Date with Unbound EditDateComboBox
Wed, Mar 2 2016 10:50 PMPermanent Link

Richard Harding

Wise Nutrition Coaching

I am using an unbound EditDateComboBox and enter a date into the edit box. The SelectedDate property is only updated when the dropdown calender is clicked.

This only occurs on unbound controls.

Example 1:
* enter '01/01/2016' in the EditDateComboBox edit box.
* click the 'Do something' button.
* SelectedDate is set to the default date, the Current Date.

Example 2:
* enter '01/01/2016' in the EditDateComboBox edit box.
* click the dropdown button at the right of the EditDateComboBox.
* click the 'Do something' button.
* SelectedDate is to '01/01/2016'.

Is that the intention?

Richard Harding
Thu, Mar 3 2016 9:26 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Richard,

<< I am using an unbound EditDateComboBox and enter a date into the edit box. The SelectedDate property is only updated when the dropdown calender is clicked. >>

This is a bug.  A fix will be in 2.05.

Tim Young
Elevate Software
www.elevatesoft.com
Thu, Mar 3 2016 9:46 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Richard,

Here's the hot fix - just replace this entire method:

WebEdits unit:

function TDateEditComboBox.GetSelectedDate: DateTime;
begin
  if FCalendarControl.Visible then
     Result:=FCalendarControl.SelectedDate
  else
     begin
     if IsDate(Text) then
        Result:=StrToDate(Text)
     else
        Result:=DateTime(0);
     end;
end;

Tim Young
Elevate Software
www.elevatesoft.com
Thu, Mar 3 2016 2:58 PMPermanent Link

Richard Harding

Wise Nutrition Coaching

<<Here's the hot fix - just replace this entire method: >>

Wonderful - thank you.

Richard
Image