Article View: borland.public.delphi.winforms.controls.using
Article #174Re: How To Clear a Listbox Using an ArrayList DataSource?
From: Slagert
Date: Fri, 24 Aug 2007 16:31
Date: Fri, 24 Aug 2007 16:31
12 lines
1277 bytes
1277 bytes
Ok, I'll answer this myself since nobody seems to be listening here... To empty a Delphi .Net listbox that uses an array for a data source just set the listbox's datasource property to nil. For instance if your listbox is named MyListbox you can use the following code to remove the items from the listbox. MyListbox .DataSource := nil; There it is, now we have the answer. -Andy
Technical Details
Message-ID:
<46cf07ee$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<46c5f43d@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 1eff29,3dcc0d5f147f1726 X-Google-Attributes: gid1eff29,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit From: "Slagert" <slagert@slagert.com> Newsgroups: borland.public.delphi.winforms.controls.using References: <46c5f43d@newsgroups.borland.com> Subject: Re: How To Clear a Listbox Using an ArrayList DataSource? Date: Fri, 24 Aug 2007 09:31:16 -0700 Lines: 14 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 X-RFC2646: Format=Flowed; Response NNTP-Posting-Host: 68.6.83.169 Message-ID: <46cf07ee$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1187973102 68.6.83.169 (24 Aug 2007 09:31:42 -0700) Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail