Recent

Author Topic: Dataset EnableControls/DisableControls  (Read 235 times)

luca

  • Jr. Member
  • **
  • Posts: 91
Dataset EnableControls/DisableControls
« on: May 28, 2026, 12:10:13 pm »
Hi,
I'm working on Windows 11.

I've compiled my applications with the last version of Lazarus (4.6 32/64 bits).

I've this code
Code: Pascal  [Select][+][-]
  1. ...
  2.  qry.DisableControls;
  3.  qry.Close;
  4.  qry.Open;  
  5.  if qry.eof then exit;
  6. ...
  7.  

With the program compiled with Lazarus version 2.2.0 all is fine: no error when I move to the grid linked to the qry dataset.
With version 4.6 I receive an Access violation when I move to the grid.

I know, there is a problem on code above: if the qry is empty the controls are not enable again because no call to EnableControls is done before exit.

But my question is: has anything changed in the new version regarding the management of data controls?

Thanks

Sharfik

  • New member
  • *
  • Posts: 8
Re: Dataset EnableControls/DisableControls
« Reply #1 on: June 10, 2026, 07:40:21 am »
full code version can see?

 

TinyPortal © 2005-2018