Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Shortcut Bar
  New Posts New Posts RSS Feed - Why Manager.Icons doesn't return any icons?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Why Manager.Icons doesn't return any icons?

 Post Reply Post Reply
Author
Message
unrecognize View Drop Down
Newbie
Newbie


Joined: 22 November 2007
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote unrecognize Quote  Post ReplyReply Direct Link To This Post Topic: Why Manager.Icons doesn't return any icons?
    Posted: 25 November 2007 at 8:20pm
Hi, currently I am developing a shortcut for my program. But when I call the manager.icons , it doesn't show any icons. May I know why? Below is my code:
 
Public Class ThisPane
    Private PaneA As PaneA = New PaneA
    Private PaneB As PaneB = New PaneB
    Private PaneC As PaneC = New PaneC
 
    Private Sub ThisPane_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        CreateShortCutBar()
    End Sub
 
    Private Sub ThisPane_Resize(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Resize
        wndShortCut.SetBounds(1, 1, Me.ClientRectangle.Width - 2, Me.ClientRectangle.Height - 2)
    End Sub
 
    Private Sub createShortCutBar()
        PaneB.Visible = False
        PaneC.Visible = False

        Dim ItemA As ShortcutBarItem = wndShortCut.AddItem(ID.SHORTCUT_A, "A", PaneA.Handle.ToInt32)
        Dim ItemB As ShortcutBarItem = wndShortCut.AddItem(ID.SHORTCUT_B, "B", PaneB.Handle.ToInt32)
        Dim ItemC As ShortcutBarItem = wndShortCut.AddItem(ID.SHORTCUT_C, "C", PaneC.Handle.ToInt32)
 
        wndShortCut.Selected = ItemA
        wndShortCut.Icons = ImageManager.Icons
    End Sub
End Class
 
Thanks for help.
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 26 November 2007 at 1:07am
Hello,
Are you sure ImageManager contains icons for ID.SHORTCUT_A/B/C ?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
unrecognize View Drop Down
Newbie
Newbie


Joined: 22 November 2007
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote unrecognize Quote  Post ReplyReply Direct Link To This Post Posted: 26 November 2007 at 4:43am

Hi oleg, thanks for the reply. I am confuse, below are my questions.

How to know that I am having the icon for A, B, C? Is it the Icon A, B, C must save into Application.StartUpPath & "\bin\Icons" ? How about the icon name? The ImageManager doesn't specify which location and file.

 
thanks.
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 26 November 2007 at 10:05am
????
 
How do you load icons?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
unrecognize View Drop Down
Newbie
Newbie


Joined: 22 November 2007
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote unrecognize Quote  Post ReplyReply Direct Link To This Post Posted: 26 November 2007 at 9:10pm
I just call this: wndShortCut.Icons = ImageManager.Icons to load the icons. And I put my Icons file in Application.StartUpPath & "\Icons". But I create the Icons by using Windows Paint. Is it this is the problem ?
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 27 November 2007 at 1:08am
but how do you load icons from Application.StartUpPath & "\Icons".  to imagemanager ?
Please follow our samples. they have everything you need.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
unrecognize View Drop Down
Newbie
Newbie


Joined: 22 November 2007
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote unrecognize Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2007 at 12:32am
Hi, I really don't know how u call the Icons from. I just follow your sample code which only putting down this line: wndShortCut.Icons = ImageManager.Icons    then your icons will be loaded, why?
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2007 at 1:30am
Hi,
 
Right click on ImageManager in sample and choose Properties - you will see that icons was added to ImageManager in designtime.
 
So you can add them in designtime or manually load from files to call
ImageManager.Icons.LoadBitmap or LoadIcon
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.141 seconds.