Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Replace double quotes with something else from user entry field

Contributor ,
Aug 22, 2017 Aug 22, 2017

I need to pass Flash data to Lectora. Lectora has problem with special characters (e.g. double quotes, single quotes, line break) from Flash.

How do I identify double quotes and change them to something else? I can't do """ with quote inside. It's not acceptable.

Thanks,

TOPICS
ActionScript
787
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Aug 31, 2017 Aug 31, 2017

you can use backslash to escape any character, or use single quotes to define double quotes and double quotes to define single quotes:

var s:String=yourtextfield.text.split('""').join('whatever');

hint: use the trace statement and a new project to experiment and see how strings/arrays work.

Translate
Community Expert ,
Aug 31, 2017 Aug 31, 2017
LATEST

you can use backslash to escape any character, or use single quotes to define double quotes and double quotes to define single quotes:

var s:String=yourtextfield.text.split('""').join('whatever');

hint: use the trace statement and a new project to experiment and see how strings/arrays work.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines