Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Command Bars
  New Posts New Posts RSS Feed - addicons commandbars method
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

addicons commandbars method

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


Joined: 16 February 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote muldoon96 Quote  Post ReplyReply Direct Link To This Post Topic: addicons commandbars method
    Posted: 15 April 2008 at 11:28am
Hi
 
I am using CodeJock 11.1.3 with Progress 10.1 B. I have an ImageManager and a CommandBarFrames in my design window, and I am trying to get the CommandBarsFrame to use the icons in the ImageManager:
 
chcommandbar.commandbarsframe.icons.addicons (chimagemanager.imagemanager.icons)
 
but I get the error 'invalid component handle referenced while processing method/statement: addicons'
 
It works fine if I simply do this:
 
chcommandbar.commandbarsframe.icons = chimagemanager.imagemanager.icons
 
I am just a bit concerned doing it this way as I cannot find anything in the CodeJock documentation that says you can simply set one to equal the other - the documentation says use 'addicons' which doesn't seem to work for me.
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: 15 April 2008 at 11:53am
Hi,
Yes its "official" method to assign icons :)
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
muldoon96 View Drop Down
Newbie
Newbie


Joined: 16 February 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote muldoon96 Quote  Post ReplyReply Direct Link To This Post Posted: 15 April 2008 at 11:57am
Sorry Oleg, I'm not quite clear - you are saying that they way I am doing it is correct, and the 'addicons' method should not be used ?
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: 15 April 2008 at 12:13pm
Yes, your method is correct. 'addicons' will not work because by default CommandBarsframe.Icons returns Null.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
muldoon96 View Drop Down
Newbie
Newbie


Joined: 16 February 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote muldoon96 Quote  Post ReplyReply Direct Link To This Post Posted: 15 April 2008 at 12:22pm
Thanks Oleg.  Can I ask you two more questions on this please? 
 
I am actually adding icons to a Shortcutbar control and then setting my CommandbarsFrame icons by doing this:
 
chcommandbar.commandbarsframe.icons = chshortcutbar.shortcutbar.icons
 
Would it be better to add the icons to an ImageManager control and then set both the ShortCutBar and the CommandbarsFrame to use the icons there, as below, or does it not really matter?
 
chshortcutbar.shortcutbar.icons = chimagemanager.imagemanager.icons
 
chcommandbar.commandbarsframe.icons = chimagemanager.imagemanager.icons
 
The second question is to do with ImageManagerIcons.loadbitmap.  I am actually loading .png files and it seems to work, but the documentation says you must load .bmp files.  Is the documentation out-of-date ?
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.235 seconds.