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

Replace double quotes with something else from user entry field

Contributor ,
Aug 22, 2017 Aug 22, 2017

Copy link to clipboard

Copied

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

Views

725

Translate

Translate

Report

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.

Votes

Translate

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

Copy link to clipboard

Copied

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.

Votes

Translate

Translate

Report

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