Discussion:
Text question
Bernd Fröhlich
2016-11-30 09:59:06 UTC
Permalink
How do I assign a text that contains "?

E.g.: MyText = "This text contains "" //Obviously this does not work

In 4D I would write that as

MyText = "This text contains \""
\" is used to put " into the text variable.

How do I do that in Xojo?

Greetings from Germany,
Bernd Fröhlich

_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.com>
Bernd Fröhlich
2016-11-30 10:05:56 UTC
Permalink
Post by Bernd Fröhlich
How do I assign a text that contains "?
E.g.: MyText = "This text contains "" //Obviously this does not work
In 4D I would write that as
MyText = "This text contains \""
\" is used to put " into the text variable.
How do I do that in Xojo?
OK, found it:

Just use double-quotes:

MyText = "This text contains """

_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.com>
Gerd Wilmer
2016-11-30 10:38:00 UTC
Permalink
or use chr(34)
Post by Bernd Fröhlich
Post by Bernd Fröhlich
How do I assign a text that contains "?
E.g.: MyText = "This text contains "" //Obviously this does not work
In 4D I would write that as
MyText = "This text contains \""
\" is used to put " into the text variable.
How do I do that in Xojo?
MyText = "This text contains """
_______________________________________________
_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.com>
Jean-Luc Arnaud
2016-11-30 11:28:42 UTC
Permalink
For readability purpose, I'm used to using chr(34).

Jean-Luc Arnaud
Post by Gerd Wilmer
or use chr(34)
Post by Bernd Fröhlich
Post by Bernd Fröhlich
How do I assign a text that contains "?
E.g.: MyText = "This text contains "" //Obviously this does not work
In 4D I would write that as
MyText = "This text contains \""
\" is used to put " into the text variable.
How do I do that in Xojo?
MyText = "This text contains """
_______________________________________________
_______________________________________________
_______________________________________________
Unsubscribe by sending a message to:
<nug-leave@

Loading...