User Tag List

Results 1 to 6 of 6

Thread: Replace a string

  1. #1
    No Products Registered

    Join Date
    Dec 2008
    Posts
    24
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Replace a string

    I`m looking for a way to replace a specific string in the certain text, just like search and replace of notepad.
    Like, when I clik in "replace" it replace all the words -aaa- to "hello" and all -bbb- to "how are you ?".
    Do you guys know what extension can I use ? I thought about use String Parse but I can`t find the option.
    If anyone have an example I`ll be glad.

  2. #2
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Popcorn's Avatar
    Join Date
    Jun 2006
    Location
    Norway, Bergen
    Posts
    2,367
    Mentioned
    13 Post(s)
    Tagged
    0 Thread(s)

    Re: Replace a string

    Don't use an extension. You can do this yourself using MMF2's built'in string options. You find them under the 'Special' icon when you make a new condition.

    You need to combine the string functions with fastloops to search through the string and build up a new string with the replaced words. It's too much to explain here without having tried it myself, so try for yourself first

    If you need to learn about fastloops, there are some tutorials about it in the tutorial section.

  3. #3
    No Products Registered

    Join Date
    Dec 2008
    Posts
    24
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Replace a string

    I don`t think it will work that way..
    first of all.. when I try to load the text in a list object it fit all the text (almost 3 pages) in 2 lines !
    second.. I wanna replace at least 50 words =/

    Anyone know how can I do it?

  4. #4
    Clicker Multimedia Fusion 2 Developer

    Join Date
    Jul 2006
    Location
    Denmark
    Posts
    1,812
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Replace a string

    You could just use String Parser 2 and it's replace function.

  5. #5
    Clicker Multimedia Fusion 2 DeveloperSWF Export Module

    Join Date
    Jun 2006
    Posts
    6,773
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: Replace a string

    There's also a dedicated object for this purpose.

  6. #6
    No Products Registered

    Join Date
    Dec 2008
    Posts
    24
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Replace a string

    worked!
    thks!

Similar Threads

  1. Substring Replace and String tokenizer
    By iOSC in forum Multimedia Fusion 2 - Technical Support
    Replies: 10
    Last Post: 29th January 2013, 12:40 PM
  2. replace characters in a string?
    By Gibbon in forum Multimedia Fusion 2 - Technical Support
    Replies: 4
    Last Post: 10th October 2011, 01:31 PM
  3. Replace portions of retrieved string with commands
    By CBSection31 in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 3rd December 2010, 12:18 AM
  4. Replace sub string for variant
    By nivram in forum File Archive
    Replies: 3
    Last Post: 14th December 2009, 03:01 PM
  5. How do i replace " in string parser 2?
    By Spryz in forum Multimedia Fusion 2 - Technical Support
    Replies: 0
    Last Post: 22nd July 2008, 11:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •