Hello,
I'm following the community samples and am trying to change the icon for my add in button. Its not working however, even though I have two buttons (one 16x16, other 32x32 like in the samples). They are present in both Images and Dark Images folders too, incase that mattered. They just dont load.
The line in the DAML file
<button........ smallImage="Images\tree16.png" largeImage="Images\tree32.png">
However I also use the same images for a window icon elsewhere, and it works perfectly. I've even tried the EvilGenius16/32.png from the samples and still no luck. Meanwhile the GenericButton16/32 png's do work. I cannot find any reference to the Generic buttons anywhere in the entire project though, so I don't know if I'm missing a resource loading step or something.
Solved! Go to Solution.
I think this ProGuide explains the issue: ProGuide Content and Image Resources · Esri/arcgis-pro-sdk Wiki (github.com)
There is a difference when referencing images from DAML versus referencing images from XAML. The previous posts were DAML references, your example is XAML.
So, when you tried to apply the DAML solution to your XAML it didn't work, because the references and build actions are different for DAML and XAML.
A couple of things I discovered in working through this issue:
Thanks to everyone else who has contributed here!