Results 1 to 2 of 2

Thread: How do I set a variable from a plugin so it can be used in the next command

  1. #1
    Variable Bitrate
    Join Date
    Nov 2006

    How do I set a variable from a plugin so it can be used in the next command

    I have a plug-in in development that one of it's commands, let's say "MYPLUGIN_CMD", needs to set an RR variable.

    I do this with SDK.EXECUTE("SETVAR;MYPLUGINVAR1;prog.exe") and observe that the SETVAR is executed right after my plug-in command finishes executing as expected.

    However, if I have the following coded on a button:

    B01,.....,"MYPLUGIN_CMD;data1||RUN;$MYPLUGINVAR1$" ,"DOIT"

    I see that the SETVAR is executed AFTER the RUN command which, of course, sees no/or incorrect data in MYPLUGINVAR1 because it hasn't been created/updated yet.

    First, is there anyway to set the variable at the time the plug-in command executes to satisfy the requirements outlined above?

    Second, anyone have any ideas how to accomplish this?

    Third, in the general case shouldn't RR commands from the plug-in be logically queued by RR right after the currently executing command as they are logically output of that command. Actually the case could be made that there is an inconsistent behavior in the SDK in that SDK.GetInfo is executed immediately whereas SDK.EXECUTE is processed after all other queued commands not necessarily after the command that created it.


  2. #2
    RoadRunner Mastermind
    Auto Apps:loading...
    guino's Avatar
    Join Date
    Nov 2004
    Toronto, Canada
    The IDEAL solution would be to only execute "MYPLUGIN_CMD" and have your plugin execute BOTH: "SETVAR;MYPLUGINVAR1;prog.exe||RUN;$MYPLUGINVA R1$" -- in the case of RUN, your plugin could just launch the application already. If you want "MYPLUGIN_CMD" to have the option between setting the var and then run OR just set the var, then you can make a parameter for it.

    Another alternative (less Ideal) would be to use a delay:
    Ride Runner RR's Myspace

    "Being happy is not about having what you want, it's about wanting what you have."
    "The best things in life are always free - but that doesn't mean money can't buy you good things."

Similar Threads

  1. DigitalFX 4.0
    By JohnWPB in forum RR Skins No Longer Supported
    Replies: 5576
    Last Post: 03-27-2014, 05:48 PM
  2. How do I get the Car2PC adapter to work in RR?
    By nasa in forum Road Runner
    Replies: 125
    Last Post: 08-14-2010, 02:30 PM
  3. Replies: 0
    Last Post: 02-11-2010, 12:58 PM
  4. music defaults to first song on open
    By soundman98 in forum Road Runner
    Replies: 18
    Last Post: 11-23-2009, 03:36 AM
  5. Set Label to dsplay Variable
    By mukow in forum RR Skins
    Replies: 2
    Last Post: 03-07-2008, 12:03 AM


Posting Permissions

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