1
In a simple routine to feed a Clientdataset, first execute the command ClientDataSet.DisableControls (before the try) and at the end of while (in the finally), execute the command ClientDataSet.EnableControls.
But the problem is that the controls of Clientdataset are not entitled to EnableControls.
I realized that if I perform more often in the sequence the EnableControls, then yes the controls are restored.
Searching the web, I saw that this problem is not new.
http://www.tek-tips.com/viewthread.cfm?qid=203983
Anyway, I want to know:
It’s safe to use the DisableControls/EnableControls?
Is there some detail needed for these commands to work, or is it really another bug delphi?
I did notice a problem in the routine, the
DisableControlswas inside awhile, whereas theEnableControlswas out...DisableControlsbefore thewhile(had not realized due to the complexity of the routine and because there was more than one loop in it).– Andrey