Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   GUI-Design mit VCL / FireMonkey / Common Controls (https://www.delphipraxis.net/18-gui-design-mit-vcl-firemonkey-common-controls/)
-   -   Delphi TListbox mit Scrollbars (https://www.delphipraxis.net/8842-tlistbox-mit-scrollbars.html)

Florian H 13. Sep 2003 08:02


TListbox mit Scrollbars
 
Hi,

wie kann ich einer TListbox eine Scrollbar verpassen?
Gibt ja keine Eigenschaft dafür...


Viele Grüße
Flo

sakura 13. Sep 2003 08:05

Re: TListbox mit Scrollbars
 
Die Listbox zeigt die Scrollbars doch automatisch an, sobald zu viele Items da sind, um alle gleichzeitig darzustellen.

...:cat:...

Florian H 13. Sep 2003 08:11

Re: TListbox mit Scrollbars
 
Achso sorry, ich meine horizontale Scrollbars!!
also wenn die items zu lang sind!

sakura 13. Sep 2003 08:17

Re: TListbox mit Scrollbars
 
Du musst die Eigenschaft ScrollWidth auf z.B. 500 setzen.

...:cat:...

Florian H 13. Sep 2003 19:57

Re: TListbox mit Scrollbars
 
Ah danke!
Und wie bekomme ich raus, wie breit der breiteste Eintrag ist?

Christian Seehase 14. Sep 2003 00:50

Re: TListbox mit Scrollbars
 
Moin Florian,

so solltest Du herausbekommen können, wie breit ein Eintrag ist.
In diesem Beispiel der letzte in der ListBox

Delphi-Quellcode:
  ListBox1.Canvas.TextWidth(ListBox1.Items[ListBox1.Items.Count-1]);


Alle Zeitangaben in WEZ +1. Es ist jetzt 04:17 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz