# EasyMultiTagging: Change tag/untag icons during runtime

**URL:** <https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280>\
**Category:** questions\
**Tags:** browse\
**Created:** [July 2, 2021, 12:32pm UTC](https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280 "2021-07-02T12:32:09Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Koen](https://clarionhub.com/letter_avatar_proxy/v4/letter/k/a9a28c/32.png) [@Koen](https://clarionhub.com/u/Koen)\
**Post date:** [July 2, 2021, 12:32pm UTC](https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280/1 "2021-07-02T12:32:10Z")

</div>

Hi All,

I have a question on EasyMultiTagging. I tried to ask support but I  
would give it a shot here also.

EMT is working fine on the browses I use it for. But so far I am not  
able to change the tag/untag icons during runtime. The idea is that  
based on some choice the user makes the list box can be enabled or  
disabled. When the list box is disabled I would like to replace the  
tag/untag icons by "disabled icon" versions.

I tried to use this lines in ThisWindow.Reset():

IF UseBrowse = True  
ENABLE(?MyBrowse)  
MultiTag:9.SetStyleIcon('~EMTmarkB.ico','~EMTblank.ico',)  
ELSE  
DISABLE(?MyBrowse)

MultiTag:9.SetStyleIcon('~EMTmarkB\_Disabled.ico','~EMTblank\_Disabled.ico',)  
END

Unfortunate that doesn't work for the icons.

Has anybody an idea how I can do this?

---

<div class="post-metadata">

**Author:** ![Clarion\_clarion](https://clarionhub.com/user_avatar/clarionhub.com/clarion_clarion/32/636_2.png) [@Clarion\_clarion](https://clarionhub.com/u/Clarion_clarion)\
**Post date:** [July 2, 2021, 5:34pm UTC](https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280/2 "2021-07-02T17:34:53Z")

</div>

The SetStyleIcon method is used only when the BrowseBox is initialized because it changes its structure: a place for the icon is allocated in the structure.

Your problem can be solved with the following code:

```
IF UseBrowse = True
           ?MyBrowse{PROP:IconList, EMT:ICONLIST_MARK} = '~EMTmarkB.ico'
           ?MyBrowse{PROP:IconList, EMT:ICONLIST_BLANK} = '~EMTblank.ico'
           ENABLE (?MyBrowse)
ELSE
           ?MyBrowse{PROP:IconList, EMT:ICONLIST_MARK} = '~EMTmarkB_Disabled.ico'
           ?MyBrowse{PROP:IconList, EMT:ICONLIST_BLANK} = '~EMTblank_Disabled.ico'
           DISABLE (?MyBrowse)
END

```

---

<div class="post-metadata">

**Author:** ![Koen](https://clarionhub.com/letter_avatar_proxy/v4/letter/k/a9a28c/32.png) [@Koen](https://clarionhub.com/u/Koen)\
**Post date:** [July 3, 2021, 9:50am UTC](https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280/3 "2021-07-03T09:50:35Z")

</div>

Hi Guennadi,

That solved the problem. Thank you. It is working fine now.  
(For those who trying too: Remove the space between the ~ and the icon name).

---

<div class="post-metadata">

**Author:** ![Clarion\_clarion](https://clarionhub.com/user_avatar/clarionhub.com/clarion_clarion/32/636_2.png) [@Clarion\_clarion](https://clarionhub.com/u/Clarion_clarion)\
**Post date:** [July 5, 2021, 12:42pm UTC](https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280/4 "2021-07-05T12:42:07Z")

</div>

Koen, thank you for your feedback.

(btw, I edited my original replay re ~ )

---

<div class="post-metadata">

**Author:** ![MarkGoldberg](https://clarionhub.com/user_avatar/clarionhub.com/markgoldberg/32/1511_2.png) [@MarkGoldberg](https://clarionhub.com/u/MarkGoldberg)\
**Post date:** [July 5, 2021, 1:43pm UTC](https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280/5 "2021-07-05T13:43:02Z")

</div>

FYI: the ~ in ‘~Yada.ico’ means that you are working with a compiled in resource instead of a file on disk

Icons that are declared inside of window structures are automatically compiled in as resources, but Icons that are just mentioned using property syntax are NOT automatically compiled in as resources, it’s up to you to do that.

See the Solution Explorer tree, inside of the project in question, highlight “Libraries, Objects and Resource Files” right click and select “add Library, Object or Resource Files(s)” in the file picking dialog change the file type to Icons, and select the Icon(s) to add

---

<div class="post-metadata">

**Author:** ![Koen](https://clarionhub.com/letter_avatar_proxy/v4/letter/k/a9a28c/32.png) [@Koen](https://clarionhub.com/u/Koen)\
**Post date:** [July 5, 2021, 2:11pm UTC](https://clarionhub.com/t/easymultitagging-change-tag-untag-icons-during-runtime/4280/6 "2021-07-05T14:11:46Z")

</div>

Yeah, I know that. I was just mentioning that there must not be a space like ‘~ Yada.ico’. That gives compile errors no matter if the icon is added as resource or not.
