Silverfrost Forums

Welcome to our forums

Dynamically update %ic after loading from DLL

10 Feb 2015 12:35 #15627

In the past we have built the resources into the .exe and using %ic with a subsequent WINDOW_UPDATE@ has permitted the icon to be dynamically updated. For example, on the Clearwin+ dialog we have an icon to represent left and another for right : when we depress the left / right keyboard keys we immediately update the icon.

This does not now happen when getting the icon from the application's DLL. Using GetModuleHandle and LoadImage and then %ic is perfectly fine for the initial display of the icon within the Clearwin+ dialog. But when we recognise the keyboard arrow key - using %ac - and perform the callback the icon update fails. When escaping and re-presenting the Clearwin+ dialog - with the new icon handle - the intended icon now displays fine.

Has the environment change caused a problem ?

10 Feb 2015 4:44 #15630

I think that we would need a short sample program and dll in order to work out the difference.

Please login to reply.