Sensor monitor custom Icons...

Hi all.

I developed a custom plug-in based on your sensor monitor. My client wants to upload his own icons. But if I use a standard icon in my dll plugin (icon = Resources.IconName), it works fine. If I use "icon = Icon.ExtractAssociatedIcon (iconpath), the icon is loaded by the management client and not in the smart client (an X appears as an icon).

How can I do that?

Thanks.

Ciao.

Gigi

Hi,

Please be aware that the icons are loaded by the Event Server plugin so the files needs to be accessible on that machine and by the Event Server service (so might also be a user rights issue).

Also please ensure that the icon format is correct as stated for the MapIcon property here:

https://doc.developer.milestonesys.com/html/index.html?base=miphelp/class_video_o_s_1_1_platform_1_1_admin_1_1_item_node.html&tree=tree_search.html?search=plugindefinition

Best regards,

Peter

Hello Peter.

Thanks for your answer but I had already verified these things.

All icons are accessible from EventServer and all icons are loaded with the 6 sizes 8x8 … 64x64.

In fact, in the management console I see the correct icon. I don’t see it only in the Smart Client (X icon appair).

Ciao.

Gigi

Hi Luigi,

How have you verified that the icon is loaded correctly in the Event Server? Have you tried debugging the process and seeing that the icon is correct after loading?

If that is the case could you please upload the icon file here and we can then try doing the same here. Also could you please provide the exact lines where you load the icon and set MapIcon property?

Br,

Peter

Resolved.

I was wrong to load the icon. I don’t know why, but using Icon.ExtractAssociatedIcon (iconPath) the SmartClient doesn’t display the icon.

Using new Icon(iconPath) instead, it works well.

Thanks and happy new year.

Gigi