Print Page | Close Window

Mass load icons into imagemanager?

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=15690
Printed Date: 27 February 2025 at 8:49am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Mass load icons into imagemanager?
Posted By: xvisceral
Subject: Mass load icons into imagemanager?
Date Posted: 22 November 2009 at 4:06pm
Okay, so I have an imagelist that I really like that I have been using in my projects.

I recently switched my GUI to include codejock controls because it looks 1000x better.

The listview when you right click it, you cannot assign an imagelist, or a SmallIcon property. You have to use their imagemanager to load icons as far as I know.

Is there a way that I could possibly either load all of the imagelist into the imagemanager, or any way around this?

Maybe a way to mass add a folder of icons into a imagemanager?

I've tried something along the lines of...
Quote Dim IcoPath As String
Dim i As Integer
For i = 1 To 247
IcoPath = "C:\fam\" & "picture" & i  & ".gif"
With ImageManager1
.Icons.LoadIcon(IcoPath, i, xtpImageNormal)
Next i
End With


Of course that didn't work...
Help? :D

I know I could just add all of the icons to an imagemanager manually but theres 247 pictures



Replies:
Posted By: Oleg
Date Posted: 23 November 2009 at 5:02am
Hi,
try LoadBitmap instead of LoadIcon.


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: xvisceral
Date Posted: 23 November 2009 at 5:12pm
Private Sub Form_Load()
Dim IcoPath As String
Dim i As Integer
For i = 1 To 247
IcoPath = "C:\fam\" & "picture (" & i & ")" & ".gif"
ImageManager1.Icons.LoadBitmap IcoPath, 1, xtpImageNormal
Next i
ListView1.Icons = ImageManager1.Icons
ListView1.ColumnHeaders.Add , , "hello", 2000
With ListView1.ListItems.Add
.Text = "About me"
.Icon = 1
End With
End Sub


Is not working for me...



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net