Error XS9078 All elements of a string concatenation must be of type 'string'. El

This forum is meant for questions and discussions about the X# language and tools
Post Reply
ic2
Posts: 1858
Joined: Sun Feb 28, 2016 11:30 pm
Location: Holland

Error XS9078 All elements of a string concatenation must be of type 'string'. El

Post by ic2 »

Another error, this worked as well last year:

Error XS9078 All elements of a string concatenation must be of type 'string'. Element 2 is of type 'dword'

LogEvents("IC2WebExchangeWCF2",0,Null_Object,"Length cText: "+slen(cText),0,"")

Slen is not a dword but a string. What is wrong here?

Dick
User avatar
wriedmann
Posts: 3755
Joined: Mon Nov 02, 2015 5:07 pm
Location: Italy

Error XS9078 All elements of a string concatenation must be of type 'string'. El

Post by wriedmann »

Hi Dick,
the SLen() function in VO and X# returns a dword, not a string.

Do you have redefined that funtion to return a string?

Wolfgang
Wolfgang Riedmann
Meran, South Tyrol, Italy
wolfgang@riedmann.it
https://www.riedmann.it - https://docs.xsharp.it
ic2
Posts: 1858
Joined: Sun Feb 28, 2016 11:30 pm
Location: Holland

Error XS9078 All elements of a string concatenation must be of type 'string'. El

Post by ic2 »

Hello Wolfgang,



That's fast!

You ae absolutely right. I think I have a few instances in m,y program where I incorrectly assumed the "S" converts the outcome to a string.

It used to work however, and that it doesn't anymore is not more than fair :)

Dick
User avatar
Chris
Posts: 4906
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

Error XS9078 All elements of a string concatenation must be of type 'string'. El

Post by Chris »

Hi Dick,

Yes, that was a bug in the compiler, it was not reporting an error when adding a string to an int, word etc. This was fixed a few builds ago.
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
Post Reply