how do I run a tcl from another tcl?

Homepage Clovertech Forums Read Only Archives Cloverleaf Cloverleaf how do I run a tcl from another tcl?

  • Creator
    Topic
  • #55829
    Gene Millard
    Participant

    What command do I use to run a tcl from another tcl?

    Gene Millard

    The Guthrie Clinic
    Sayre, PA

Viewing 3 reply threads
  • Author
    Replies
    • #86633
      Charlie Bursell
      Participant

      Engine proc or script?  If engine proc and in tclIndex simply execute it.   If script you could use the exec command.

      My suggestion.  Put it in a package and then “package require” and simply execute it.

    • #86634
      Gene Millard
      Participant

      How do I tell if it is in the tclIndex?

      What command do you use to execute it?

      I do not know how to create a package?

      The Guthrie Clinic
      Sayre, PA

    • #86635
      Mark Thompson
      Participant

      Hello Gene,

      Once you have “indexed” a Tcl proc (using mktclindex) you can call it by name from any other proc.

      You can view the output of mktclindex in $HCISITEDIR/tclprocs/tclIndex  That will show you the proc name and the file to “source” (load into memory) when the proc is first called.

      That said, there are several different structures for Tcl procs used by Cloverleaf.  Usually you will only call a proc of type “Other” from your proc.  Procs types like tps, trx or xltp are designed to be called directly from the engine (or testing tool).  You probably don’t want to try calling them from your proc.

      - Mark Thompson
      HealthPartners

    • #86636
      David Barr
      Participant

      Mark Thompson wrote:

      Procs types like tps, trx or xltp are designed to be called directly from the engine (or testing tool).

Viewing 3 reply threads
  • The forum ‘Cloverleaf’ is closed to new topics and replies.

Forum Statistics

Registered Users
5,117
Forums
28
Topics
9,292
Replies
34,432
Topic Tags
286
Empty Topic Tags
10