Solved

CheckBoxes as children of Tabbed Notebooks?

Posted on 1997-03-25
2
369 Views
Last Modified: 2010-04-04
This is in Delphi 1.0

I have a tabbed notebook with multiple check boxes on each page.  Is there a way to access these check box controls as children of the notebook (like you can do with controls in a group box)?  I want to be able to set the Checked property of all of the checkboxes to true or false without having to access each one by it's name.  I can't find any reference to doing it with tabbed notebooks.

Jody
0
Comment
Question by:jodyl
2 Comments
 
LVL 3

Accepted Solution

by:
sperling earned 70 total points
ID: 1334949
procedure SetCheckboxes (ANotebook : TTabbedNotebook; APage : INTEGER; Checked : BOOLEAN);
var
  ndx     : INTEGER;
begin
  with TTabPage(ANotebook.Pages.Objects[APage]) do begin
    for ndx :=  0 to ControlCOunt-1 do begin
      if Controls[ndx] is TCheckBox then TCheckBox(Controls[ndx]).Checked := Checked;
    end;
  end;
end;


Use this proc... The APage parameter is 0-base page index.

Regards,

Erik.
0
 

Author Comment

by:jodyl
ID: 1334951
It ain't documented as far as I know.

I once needed to find out how to create a control run-time, and place it on a given notebook page, therefore I just looked through the VCL source.


Regards,

Erik.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Memory leak using records in a TVirtualStringTree 11 109
Show Listview image from database (String field) 5 112
can't find the executable in Simulator 1 80
update joined tables 2 31
A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now