Link to home
Start Free TrialLog in
Avatar of TonyDelphiHunt
TonyDelphiHuntFlag for Afghanistan

asked on

data changes not posted

I have a simple app which has several tdbedit fields and a button to post data.

If I edit a field and press the post button before I tab out of the field, the data is lost.

This sounds SO trivial I'm embarrassed to ask but there you go..
I'm asking.............. What can I do.
ASKER CERTIFIED SOLUTION
Avatar of TheRealLoki
TheRealLoki
Flag of New Zealand image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of TonyDelphiHunt

ASKER

Well, what can I say...... I was looking at a tiny sample of code to show the problem and I couldn't re-produce it.......................................

After much anguish, I found it was because in the original code I was triggering the Post with a tToolButton. My sample code was using a standard button.

When the tToolButton is pressed, focus is left with the tDBEdit that has focus, with a tButton, focus is passed to the button itself.
When the focus leaves the tdbedit, data is retained.


Weird behavior but logical (I guess). Anyway, please have the points as you were the only one to answer anyway.


Best Wishes..
I think you should ask to have your points refunded actually :-)