Jump to content
c4brian

TCL in RivieraPro

Recommended Posts

Does anyone know how to display the pathname of the currently running script in RivieraPro?

Note** This is when executing the script using the "Do" Command (Gear icon), not the "source" command.

 

aka [info script] returns an empty string, so that's out.

Share this post


Link to post
Share on other sites

You can have procedures

proc mydo {arg} {
    global RUNNING_SCRIPT_NAME
    set RUNNING_SCRIPT_NAME $arg
    do $RUNNING_SCRIPT_NAME
}

proc whatami {} {
    global RUNNING_SCRIPT_NAME
    echo $RUNNING_SCRIPT_NAME
}

And then run yours script:

mydo 2.do

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×