Article View: borland.public.cppbuilder.nativeapi
Article #9192Assigning TGraphic to descendent class
From: ScOe
Date: Fri, 23 Jul 2004 13:25
Date: Fri, 23 Jul 2004 13:25
21 lines
1263 bytes
1263 bytes
void __fastcall TCBZIconObject::SetImage (TGraphic *Value)
{
try {
FImage = new Graphics::TBitmap ();
FImage->Assign (Value);
}
catch (...) {
try {
delete FImage;
FImage = new Graphics::TIcon ();
FImage->Assign (Value);
}
catch (...) {
}
}
}
is it ok to do it like this ?
I dont receive any error msg and thing works, but maybe there is another way
to do same.
Technical Details
Message-ID:
<410111e9@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!proxad.net!gatel-ffm!gatel-ffm!194.25.134.126.MISMATCH!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,d2b0b035e2ea3f51,start X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit From: "ScOe" <cbinders@hotmail.com> Newsgroups: borland.public.cppbuilder.nativeapi Subject: Assigning TGraphic to descendent class Date: Fri, 23 Jul 2004 15:25:59 +0200 Lines: 23 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1437 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 NNTP-Posting-Host: 193.198.128.219 Message-ID: <410111e9@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1090589161 193.198.128.219 (23 Jul 2004 06:26:01 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!proxad.net!gatel-ffm!gatel-ffm!194.25.134.126.MISMATCH!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail