User Tag List

Results 1 to 9 of 9

Thread: [Howto] Make String replace in a simple text?

  1. #1
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)
    BackStaged's Avatar
    Join Date
    Aug 2010
    Location
    France
    Posts
    693
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [Howto] Make String replace in a simple text?

    I know about Mid$, Right$ and Left$.

    But the result was unexpected.
    Because IT EXTRACT only
    Not that i research..
    I search a String Replacing method (for all those know, by example: str_replace() it's very simple, and especially strong!, If you know some extensions which can do that, say to me please!)

    Then about my problem, it's simple..
    (in theory) Due to a Recursive folding list, i must DELETE the chain Apppath$ from the rest of the "text".

    (in practical) But, I dunnow how to make that, i've got angry because i'm tired of this sh*skl.. harrr..

    (in mess) So, if you can said to me HOW replacing A simple text in a String; it would be so coool!

    -please, help me- lol. So, thanks and i hope take an answer (and good if possible lol) (VERY) soon!!

  2. #2
    Clickteam Clickteam
    LB's Avatar
    Join Date
    Jun 2007
    Location
    Richardson, Texas, North America
    Posts
    8,937
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    http://ext.neatwares.ath.cx/ext/Substring_Replace
    Working as fast as I can on Fusion 3

  3. #3
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)
    BackStaged's Avatar
    Join Date
    Aug 2010
    Location
    France
    Posts
    693
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    Ok ok, no answer, but i've found a Magic Extension.
    Her name: .net Input Script
    Coded by: Greyhill

    MILLIONS OF THANKS TO HIM/HER (and also because I LOVE the C# Language since i've tested the XNA Game Framework, but XNA is so complex, i'm overruned by events)

    It allow we to use the POWERFUL Framework .NET library, through MMF2. (by the way of C# or VB.NET).

    Then i had coded this :

    Code:
    using System;
    using System.Text;
    
    
    public class CSharpOverride
    {
    	public string StrReplacer(string DansCa, string RemplaceCeci, string ParCela)
            	{
                		string DonneeDeRetour = "";
    					DonneeDeRetour = DansCa.Replace(RemplaceCeci, ParCela);
    					return DonneeDeRetour;
           	}
    }
    And i was able now to USE the Replacing functions of FrameWork .NET!
    Oh.

    and usage it's:

    CallFunction$( "[color:#33CC00].netExtensionFramework[/color]", "[color:#000099]CSharpOverride[/color][color:#CC0000].[/color][color:#003333]StrReplacer[/color]", ("where|what|bywhat"))

    [color:#33CC00].netExtensionFramework[/color] : IS : the ObjectName of .net Input Script when added to your frame.
    [color:#000099]CSharpOverride[/color] : IS : the ClassName of .net code for yours functions.

    DON'T FORGET THE "[color:#CC0000].[/color]" IT'S IMPORTANT FOR ACCESSING CLASSPROPERTIES builtin Functions!

    [color:#003333]StrReplacer[/color] : IS : the InClassFunctionName in the ClassProperties Functions.

    And, adapt the:

    "where" to: Where you want find and replacing characters/strings
    "what" to: What do you want search for replacing
    "bywhat" to: The replace value

  4. #4
    Clickteam Clickteam
    LB's Avatar
    Join Date
    Jun 2007
    Location
    Richardson, Texas, North America
    Posts
    8,937
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    You didn't see my reply. Scroll up.
    Working as fast as I can on Fusion 3

  5. #5
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)
    BackStaged's Avatar
    Join Date
    Aug 2010
    Location
    France
    Posts
    693
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    Quote Originally Posted by LB
    http://ext.neatwares.ath.cx/ext/Substring_Replace
    Holythanks for sure !

    But, you should really try Extension .net Input Script, it's POWERFUL, nothing can stop!

    Really a Miracle Extension

  6. #6
    Clickteam Clickteam
    LB's Avatar
    Join Date
    Jun 2007
    Location
    Richardson, Texas, North America
    Posts
    8,937
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    There is also the XLua Extension
    Working as fast as I can on Fusion 3

  7. #7
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)
    BackStaged's Avatar
    Join Date
    Aug 2010
    Location
    France
    Posts
    693
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    UP!

    I had make some mistakes when i wrote in .NET for MMF2, so, please, check my full english tutorial here: http://www.clickteam.com/epicenter/ubbthreads.php?ubb=showflat&Number=204173

    @LB: Did you have some websites where i can see how XLua extension work for MMF2 ?

  8. #8
    Clickteam Clickteam
    LB's Avatar
    Join Date
    Jun 2007
    Location
    Richardson, Texas, North America
    Posts
    8,937
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    Quote Originally Posted by BackStaged
    @LB: Did you have some websites where i can see how XLua extension work for MMF2?
    Yep!
    http://www.clickteam.com/epicenter/ubbthreads.php?ubb=postlist&Board=89&page=1
    Working as fast as I can on Fusion 3

  9. #9
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)
    BackStaged's Avatar
    Join Date
    Aug 2010
    Location
    France
    Posts
    693
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: [Howto] Make String replace in a simple text?

    Excellent, thanks for the link!

    It's really interesting.

Similar Threads

  1. Replies: 5
    Last Post: 30th December 2013, 07:01 AM
  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 sub string for variant
    By nivram in forum File Archive
    Replies: 3
    Last Post: 14th December 2009, 03:01 PM
  4. Replace a string
    By rootg in forum File Archive
    Replies: 5
    Last Post: 2nd January 2009, 06:08 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
  •