I have a list of checkboxes on a form:
| | Mediation held; agreement reached
| | Dispute Resolved
| | Vacate Setting
| | Set for hearing
| | Keep existing setting
| | Mediation held; No agreement
I have a private variable on the form sDocketText. I want to write a single procedure that when any checkbox is checked that writes the caption of the checked box to sDocketText.
I'm sure I need to use some form of
Although, now that I'm posting this, I also need to remove the text if they uncheck the box, so maybe a StringList to hold the captions?
Anyway, the bigger issue is getting the caption of the checkbox that was selected into my variable.
Any thoughts?
Leslie
Anything worth doing is a lot more difficult than it's worth - Unknown Induhvidual
Essential reading for database developers:
The Fundamentals of Relational Database Design
Understanding SQL Joins
| | Mediation held; agreement reached
| | Dispute Resolved
| | Vacate Setting
| | Set for hearing
| | Keep existing setting
| | Mediation held; No agreement
I have a private variable on the form sDocketText. I want to write a single procedure that when any checkbox is checked that writes the caption of the checked box to sDocketText.
I'm sure I need to use some form of
Code:
with Components as TCheckBox do
begin
sDocketText := sDocketText + Component.Caption
end;
Although, now that I'm posting this, I also need to remove the text if they uncheck the box, so maybe a StringList to hold the captions?
Anyway, the bigger issue is getting the caption of the checkbox that was selected into my variable.
Any thoughts?
Leslie
Anything worth doing is a lot more difficult than it's worth - Unknown Induhvidual
Essential reading for database developers:
The Fundamentals of Relational Database Design
Understanding SQL Joins