Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 202
  • Last Modified:

Flash: I need to be able to translate characters

I need to be able to translate "a" to "k" or "4" to "q" and so on.

Is there an easy way to do this with actionscript?

Any help or advice would be great. I'm a perl guy, so if there is something similar to $line =~ tr/[1234567890]/[abcdefghij]/; that would be great :)

The swf file needs to be stand alone...   otherwise I'd use a perl script.

Thank you very much.

Best regards,

Dr34m3r

0
dr34m3rs
Asked:
dr34m3rs
  • 2
  • 2
1 Solution
 
hsmtpCommented:
Try RegExp class for Flash: http://www.jurjans.lv/flash/RegExp.html
0
 
dr34m3rsAuthor Commented:
How do I implement that class? Where do I put the file, what code do I use and where?

Thank you very much.

Best regards,

Dr34m3r
0
 
hsmtpCommented:
Dr34m3r,

Get this file: http://www.jurjans.lv/flash/RegExp.zip
It has examples of use.

Include the class in the first frame (take care about path from your .fla to it):

#include "RegExp.as"

You'll also find a brief documentation at this page: http://www.jurjans.lv/flash/RegExp.html

But take a look at the sample - it has more then documentation.
0
 
dr34m3rsAuthor Commented:
Hey there :)

Sorry it took so long to get back to you on this.

Thank you for all your help in this matter!!!

Best regards,

Dr34m3r
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now