Question about ListBox |
Post Reply |
Author | |
Kamand.Jirbande
Newbie Joined: 20 December 2008 Status: Offline Points: 3 |
Post Options
Thanks(0)
Posted: 20 December 2008 at 1:56am |
Hi,
Anyone knows how can I load icons to ListBox from ImageList or ImageManager?
I don't wanna load icons from disk or resources.
If anyone have a sample, please give me. Thanks:)
I add items like this:
ListBoxMarkup.AddItem "<Border BorderThickness='2' BorderBrush='DodgerBlue' Margin='0, 2, 0, 2' Padding='3'><StackPanel Orientation='Horizontal'>" & _
"<Image Source='30'/>" & _ "<Grid><Grid.ColumnDefinitions><ColumnDefinition Width='Auto'/><ColumnDefinition Width='*'/></Grid.ColumnDefinitions>" & _ "<Grid.RowDefinitions><RowDefinition/><RowDefinition/></Grid.RowDefinitions>" & _ "<TextBlock TextAlignment='Right' FontWeight='Bold' Foreground='Navy' Text='IP:'/>" & _ "<TextBlock TextAlignment='Right' Grid.Row='1' FontWeight='Bold' Foreground='Navy' Text='Country:'/>" & _ "<TextBlock Margin='6, 0, 0, 0' Grid.Column='1' Text='" & MyResult(0) & "'/>" & _ "<TextBlock Margin='6, 0, 0, 0' Grid.Column='1' Grid.Row='1' Text='" & "Loopback" & "'/>" & _ "</Grid></StackPanel></Border>" |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi,
Add ImageManager to form, add icons in design time and in code add
XtremeSuiteControls.Icons.AddIcons YourImageManager.Icons
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
nighthawk
Senior Member Joined: 11 June 2004 Status: Offline Points: 167 |
Post Options
Thanks(0)
|
When using the AddIcons function, does it create a copy of icons from the ImageManager or does it just create a pointer to the icons. The reason I ask is that I have one ImageManager with all my icons that I use for the CommandBars, ReportControl, SuiteControls, etc. I don't want to have a seperate copy of the icons in memory for each type of control.
Also, why doesn't the following work on the global settings object: Set XtremeSuiteControls.Icons = MyImageManager.Icons The code above gives me an error but it works if set it to an individual control such as: Set objReportControl.Icons = MyImageManager.Icons |
|
Product: Xtreme SuitePro (ActiveX) version 13.0.0
Platform: Windows XP (32bit) - SP 3 Language: Visual Basic 6.0 |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hello,
AddIcons will copy icons. BUt our ImageManager hold all icons in single bitmap so it will not create additional GDI Handlers.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |