Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CALL THE PROCEDURE

Status
Not open for further replies.

gmie

Programmer
Sep 6, 2001
29
0
0
MY
Hello guys....

I have a problem here. Here my code....

procedure LoadPMINOData;
begin
DataModule_SP.QueryLookup.SQL.Clear;
sSQL := 'Select distinct (rg_person.current_icno)scurrent_icno, (rg_person.old_icno)sold_icno, (rg_person.date_of_birth)sdate_of_birth, ';
sSQL := sSQL + '(rg_person.first_name)sfirst_name, (rg_person.last_name)slast_name, (rg_person.email)semail from rg_person ';
sSQL := sSQL + 'inner join rg_patient on rg_patient.person_id = rg_person.id ';
sSQL := sSQL + 'where rg_patient.pmino = ' + '"' + pminonyer + '"';
DataModule_SP.QueryLookup.SQL.Add(sSQL);
DataModule_SP.QueryLookup.ExecSQL;
DataModule_SP.DataSourceSP.DataSet.Open;
While Not DataModule_SP.DataSourceSP.DataSet.eof do
Begin
frameBiodata.edtNewICNumber.Text := DataModule_SP.DataSourceSP.DataSet.FieldByName('scurrent_icno').asString;
frameBiodata.edtOldICNumber.Text := DataModule_SP.DataSourceSP.DataSet.FieldByName('sold_icno').asString;
frameBiodata.edtDOB.Text := DataModule_SP.DataSourceSP.DataSet.FieldByName('sdate_of_birth').asString;
frameBiodata.edtFirstName.Text := DataModule_SP.DataSourceSP.DataSet.FieldByName('sfirst_name').asString;
frameBiodata.edtLastName.Text := DataModule_SP.DataSourceSP.DataSet.FieldByName('slast_name').asString;
frameBiodata.edtEmail.Text := DataModule_SP.DataSourceSP.DataSet.FieldByName('semail').asString;
DataModule_SP.DataSourceSP.DataSet.Next;
End;

end;

...this code ip in UnitBiodata and I want call it UnitMainMenu(it is onder buttonclick)

Can someone teash me how to call this procedure in UnitMainMenu.

Please help me

TQ
 
Open UnitMainMenu, click file, click use unit

Regards S. van Els
SAvanEls@cq-link.sr
 
Well I use all units in my project, the error still the same. And for your information frameBiodata is a object(TFrame).

What should I do next..?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top