Bem Bia
asked on
DBGrid or StringGrid ?
Dentists programm.
MySQL tables:
manipulation
tooth
Question
When i want to chose tooth on a manipulation delphi form i need to use dentition form like this:
Numbers (18,17.......37,38) are names of teeth, 2 fields for mucous membrane and paradontitis.
I think primitive way - create many buttons named as 18,17.........37,38, mucous membrane, paradontitis,
how can i do this with dbgrid or stringgrid (with 2 horizontal rows), fields to mucous membrane and paradontitis will be buttons?
MySQL tables:
manipulation
- mid
- tid (foreign key tooth.tid)
tooth
- tid
- tname
Question
When i want to chose tooth on a manipulation delphi form i need to use dentition form like this:
Numbers (18,17.......37,38) are names of teeth, 2 fields for mucous membrane and paradontitis.
I think primitive way - create many buttons named as 18,17.........37,38, mucous membrane, paradontitis,
how can i do this with dbgrid or stringgrid (with 2 horizontal rows), fields to mucous membrane and paradontitis will be buttons?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Is this the homework? Have you tried anything?
ASKER
Thanks for help,
how can i get Teeth(I)? i named
procedure TForm1.TeethClick(Sender: TObject);
var btn: TButton;
begin
btn := TButton(Sender);
query.Sql.Clear;
query.Sql.TExt:= 'INSERT INTO manipulation (mid, tid) Values (:mid, :tid) on duplicate key update tid= :t';
query.Parameters.ParamByName('manidx').Value := manipulationid;
query.Parameters.ParamByName('t').Value :=
how can i get Teeth(I)? i named
query.Parameters.ParamByName('t').Value := btn.Tag
and result is NULL
ASKER
No, its not my homework, when i was studying in university i was not intrested in learning information technologies :) I was stupid and now i have a chance to participate in competition.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you