Search code examples
externalibm-doors

Calling an external program from DXL


Specifically, a perl script. Parameters need to be passed, but nothing needs to be returned.

I've searched the web and the Reference Manual, with no results.


Solution

  • The answer depends a bit on the operating system you are using. You may ecute a command by using the function

    void system(string command)
    

    on Windows. On Unix, use

    void system(string command, void childCB(int) [,void parentCB()])
    

    Check the DXL Reference Manual, Chapter 10 Operating system interface for details. Here is example usage:

    if (platform=="WIN32")
        system "notepad"