[Gambas-bugtracker] Bug #2556: Message.Error - Unable to load image

bugtracker at gambaswiki.org bugtracker at gambaswiki.org
Tue May 24 19:17:38 CEST 2022


Comment #3 by Bruce STEERS:

Error.Text messages are just filled internally during operation.
Consider this code within a program..

Try hImg = Image.Load(sImageName & ".svg")
If Error Then hImg = Image.Load(sImageName & ".png)

imagine ImageName.svg does not exist but ImageName.png does.

Because Try has been used the program does not raise an error but Error.Text will now contain a message about no svg file found.

So if you look at Error.Text later it just contains the last error message. Not a bug, just internal workings.

I assume your button does actually show the picture so regardless of Error.Text there has not been an actual error and it's working properly.

More information about the Bugtracker mailing list