Re: Check if object is created or not

From: Mike Shkolnik (mshkolnik2002_at_ukr.net)
Date: 01/11/05


Date: Tue, 11 Jan 2005 12:56:20 +0200

var
  yourBitmap: TBitmap;
begin
  if not Assigned(yourBitmap) then
  begin
    yourBitmap := TBitmap.Create;
    <some code to initialize the yourBitmap>
  end;
  <some code to work with yourBitmap>
end;

So all what you need is to use the Assigned() function

--
With best regards, Mike Shkolnik
EMail: mshkolnik@scalabium.com
http://www.scalabium.com
"René Jensen" <not4u2know@privacy.org> wrote in message
news:crv10c$kkj$1@news.net.uni-c.dk...
> Hi,
>
> I've got a procedure with a variable referenced parameter to a TBitmap
> object. I need some source code to check if the object has already been
> created, with the TBitmap.Create-method, or not. Anyone?
>
> Kind regards,
> Rene Jensen