Macro that requests input for the "Replace" value

Home Forums Multi-Edit User Created Macros Macro that requests input for the "Replace" value

This topic contains 1 reply, has 2 voices, and was last updated by  Clay Martin 4 years, 2 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #3005

    JRushmeyer
    Participant

    OK, guys. I am just a trial user right now. I used ME when I worked for the State of Ohio but that was a few years ago. I want to write a macro that will search for a particular phrase and then ask what I want the replacement value to be. I found and figured out how to do a simple replace using ME’s example

    VOID STEP_3()
    {
    Ignore_Case= True;
    while ( Search_Fwd("{\" value=\"}",0)) Replace(‘,’);
    }

    but what I would like to do is have it ask me (or I can put the value in the command line…which I am still trying to figure out how to do that while I am in ME. My clumsy simple attempt was

    VOID REP_TEST()
    {
    Ignore_Case= True;
    while ( Search_Fwd("{vote}", 0)) Replace( mparm_str);
    }

    just to see if I could get something really simple to work but all that does is replace vote with a blank space. (and doesnt ask me for the input valye.) I readl about doing it

    Rep_test("JR");

    but not sure how that works unless it means I need to write a simple app and incorporate it into the app.
    I can survive if this wont work the way I want it too (using the Macro/Run dropdown) but it would be really nice if I could get it to work…and
    a big incentive to buy the software too!!!!

    Thanks
    John Rushmeyer
    Columbus OH

    #21245

    Clay Martin
    Keymaster

    Hi John,
    To get input you should search the CMac guide for Menus and Dialog Boxes.

    On this forum is a series of cmac tutorials. There is one on dialogs for input. start here
    http://multieditsoftware.com/forums/topic/introduction-to-cmac-1-hello-world/

    Thanks,
    Clay

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.