Jump to content

Changing the application icon at run-time


Recommended Posts

Hey everyone! 

I've looked through google and the lavag forums for this problem and haven't found much so I thought I'd ask and see if anyone had some ideas.

Problem:  I have an executable that is launching applets from several different PPLs.  I am defining what PPL should be loaded by passing an INI file as command line arguments and also providing any other important start up information in that file.  I've been trying to also force the icon on the application to set so that, depending on what the user is doing, the icon matches the process that I'm presenting them.

Originally I thought this to be rather trivial as LabVIEW provides an invoke node to set the icon but after attempting it (and then checking the documentation) I realized that it is not available at run-time, (also it doesn't support .ico files according to the docs)

http://zone.ni.com/reference/en-XX/help/371361R-01/lvprop/vi_set_vi_icon/

My hope is that I can force the application icon on the start bar and the title bar to match the .ico file that I'm providing to LabVIEW from the ini file.  Any thoughts on this?  I assumed it would be rather simple, just a function call to the right property/invoke/activex node but I've not come up with much at this point

 

Thanks for your help,

Tim

Link to comment

Over the years I've been using a portable version of Gimp for ICO file editing.  In Windows 10 I've found that having 256x256, 48x48, 32,32, and 16x16 work well.  I mean you can have 128x128, 96x96, and any others but it becomes a support problem having to make all those for every application.

  • Thanks 1
Link to comment
  • 5 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.