04-30-2020 06:41
04-30-2020 06:41
Hi,
I have a real mystery I try to fill an html element with a color which doesn't work. I'm converted my current message code to a file transfer.
///In companion I do:
04-30-2020 07:07
04-30-2020 07:07
What does the data your are encoding? just a string value ex.
"gold"
?
04-30-2020 07:38
04-30-2020 07:38
yes just a value with a valid css color
04-30-2020 13:57
04-30-2020 13:57
My theory is that colour names are converted to numbers at build time. At run time, try sticking a number in there; eg, 16777215.
I suspect that no strings will work, including '16777215', '#808080', etc.
05-01-2020 02:10
05-01-2020 02:10
@Gondwana I solved the mystery somehow the string contained a start and end quote, charAt (0, properties) resulted in ".
And that became because of somehow in the process of getting the color from the colorpicker the " char was escaped, so \"gold\". I still searching how that happend because earlier when using the message connection (instead of filetransfer) it all worked fine.
Thnx for thinking along,
Robert
05-05-2020 16:39
05-05-2020 16:39
I'd inspect what `data` contains before encoding it in the companion. Because maybe it contains the `"` character at that point, and the root cause is in earlier code like the settings.