Can't clear a label's imageURL

The following does not work as I think it should:

elements.img_display.setImageURL(null)

The image that was set previously is not cleared! Other posts on the forum indicate this is the proper way to clear an image. An example solution is attached to demonstrate this problem.

imageURLClearing.servoy (3.83 KB)

I never use this but what happens when you replace null with “”?

It still doesn’t work with an empty string (“”). Believe me, I have tried every variant I could think of.

The only thing that does work is setting the image URL to a 1x1-pixel transparent spacer GIF.

It seems it was never possible to set with null value, will be possible in Servoy 3.0b3 and onwards.
In meantime you have to use the workaround (setting an transparent image)