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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Select objects with the Name

Status
Not open for further replies.

luistsousa

Technical User
May 12, 2003
66
PT
Hi

Who can I select a object with Your Name?
For Example: To delete a label with the name "label1" ?

Thanks
Luis
 
Do you want to select it or delete it? Actually, I'm not sure how you could "select" it persay, but you could modify it's properties.

Just type
Label1->Caption = "new Caption";

This is one of the most basic concepts in C++ Builder, and if you don't know it, then I suggest definitely reading the book shipped with the program or an online tutorial to get you started.

If I misunderstood and you are wondering how to delete an object in run-time that was created at design-time, then you just use the delete routine.

delete Label1;

Chris
 
I think that u are looking for a way to do something like this isn't?

any loop
{
NomVar_that_u_are_looking_for = anything;
}

If this is the case
you can use FindComponent("ComponentName");

if u need more information just let me know





---LastCyborg---
 
Hi

Thanks, is the FindComponent that I look. I explain bad. Thanks to both.

REgards
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top