Link to home
Start Free TrialLog in
Avatar of gleads
gleadsFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Refreshing data

at the moment, I have a screen that then moves to one of two forms.  The problem I have is that when I view the form, go out and select another record and go back in, the displayed data is still the data from the previous record.

I need somehow to refresh the data without clearing the SQL or the query because that looses all the SQL which specifies the records to find.  
Avatar of kretzschmar
kretzschmar
Flag of Germany image

try to establish a master-child relation
in delphi (properties mastersource,masterfield of the dataset).

otherwise you have to relocate the form2-data
in the afterscroll-event of the dataset on form1

meikl ;-)
Avatar of GummiStori
GummiStori

query1.requestlive := true;
Avatar of gleads

ASKER

requestlive what is this?
No sorry.. I meant query1.AutoRefresh := true;
It's a property in the Object Inspector

From delphi help:
"When AutoRefresh is true, field values are automatically refreshed without an explicit call to the Refresh method."

I hope it helps

Gummi St.
Avatar of gleads

ASKER

I am using an ADO connection will this still work?
ASKER CERTIFIED SOLUTION
Avatar of GummiStori
GummiStori

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 gleads

ASKER

it says insufficient base table information