[i18n] TDBINtDatePicker auto puts DataSet in dsEdit state

Please post bug reports, feature requests, or any question regarding the DELPHI AREA projects here.

[i18n] TDBINtDatePicker auto puts DataSet in dsEdit state

Postby JHarding » October 17th, 2012, 8:10 pm

Hi,

If my form contains a TDBINtDatePicker hooked to a datasource and field the DataSet state is automatically changed to dsEdit from dsBrowse. Is this a bug or am I missing something.

Thanks
JHarding
Member
Member
 
Posts: 4
Joined: October 17th, 2012, 8:07 pm

Re: [i18n] TDBINtDatePicker auto puts DataSet in dsEdit stat

Postby JHarding » October 17th, 2012, 8:22 pm

Some additional info. In my code I assign the DataSource.DataSet in the OnShow event. With the TDBINtDatePicker this calls the DataChange event which calls SetDate and Change which calls DataLink.Edit. This should not be done when no data change was made.

Thanks
JHarding
Member
Member
 
Posts: 4
Joined: October 17th, 2012, 8:07 pm

Re: [i18n] TDBINtDatePicker auto puts DataSet in dsEdit stat

Postby Kambiz » October 18th, 2012, 6:02 pm

Is TDBINtDatePicker a custom control? If yes, how can I have it to test the case.
Which version of Delphi are you using?
Kambiz
User avatar
Kambiz
Administrator
Administrator
 
Posts: 2429
Joined: March 7th, 2003, 7:10 pm

Re: [i18n] TDBINtDatePicker auto puts DataSet in dsEdit stat

Postby JHarding » October 18th, 2012, 6:13 pm

Sorry I missed the l in TDBIntlDatePicker. It's part of the i18n components nothing custom.
JHarding
Member
Member
 
Posts: 4
Joined: October 17th, 2012, 8:07 pm

Re: [i18n] TDBINtDatePicker auto puts DataSet in dsEdit stat

Postby Kambiz » October 23rd, 2012, 4:54 pm

Hi,

Sorry, last weekend I couldn't find a free time to work on this issue. I hope the next weekend thing goes better.
Kambiz
User avatar
Kambiz
Administrator
Administrator
 
Posts: 2429
Joined: March 7th, 2003, 7:10 pm

Re: [i18n] TDBINtDatePicker auto puts DataSet in dsEdit stat

Postby Kambiz » October 28th, 2012, 7:12 pm

To fix the problem, please replace TCustomDBIntlDatePicker.Change procedure in i18nDBDateCtrls.pas file with the following code.

Code: Select all
procedure TCustomDBIntlDatePicker.Change;
begin
  if not fChanging and DataLink.Edit then
  begin
    inherited Change;
    DataLink.Modified;
  end;
end;


Thanks for reporting the problem.
Kambiz
User avatar
Kambiz
Administrator
Administrator
 
Posts: 2429
Joined: March 7th, 2003, 7:10 pm


Return to DELPHI AREA Projects

Who is online

Users browsing this forum: No registered users and 4 guests

cron