🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #1633

Re: Followup - Modifying Object Properties Efficiently

#1633
From: Viatcheslav V. Vassiliev
Date: Fri, 11 Jun 2004 18:11
41 lines
2229 bytes
You could determine is control TEdit using InheritsFrom() function of the
control. Then cast it to TEdit. Another way is used in Delphi - declare
class of type TControl and case to this type:

type
    TControlAccess = class(TControl);

var
    Control: TControl;
begin
    Control := ...
    TControlAccess(Control).Color := ...
end;

//------------------------------------------
Regards,
Vassiliev V. V.
http://www.managed-vcl.com - using .Net objects in Delphi for Win32 +
ADO.Net
http://www.oledbdirect.com - The fastest way to access MS SQL Server,
MS Jet (Access) and Interbase (through OLEDB)

"Scott" <the1scot@aol.com> �������/�������� � �������� ���������:
news:40c9d6f0$1@newsgroups.borland.com...
> Thanks for the help Vassiliev!
>
> Your methd works very well for editing some properties of the edit boxes,
> such as the name, but I am unable to change the color.  The class
definition
> of TEdit lists the Color property in the published section and I am unable
> to determine a way to access the color property using the "controls" array
> you described.
>
> I really am excited about your method and wish you use it, but I need to
get
> through this problem.  Any follow-up advice would be great!
>
> Thanks again,
> Scott
>
>
Technical Details
Message-ID: <40c9f5df@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <40c9d6f0$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 10698b,b7e146461ff0f896
X-Google-Attributes: gid10698b,public
From: "Viatcheslav V. Vassiliev" <support@oledbdirect.com>
Newsgroups: borland.public.cppbuilder.database.ado
References: <40c9d6f0$1@newsgroups.borland.com>
Subject: Re: Followup - Modifying Object Properties Efficiently
Date: Fri, 11 Jun 2004 22:11:44 +0400
Lines: 43
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-Mimeole: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 213.234.218.42
Message-ID: <40c9f5df@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1086977503 213.234.218.42 (11 Jun 2004 11:11:43 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail