Sending Multiple Sequence Files to Trev under Windows.
markj at mrc-lmb.cam.ac.uk
Wed Nov 7 12:25:03 EST 2001
The sprun.exe program was only ever intended for use as part
of an installation where the user invokes it via an icon. It currently
has a hard limit of 10 arguments. I'll look into removing that limit
for the next update, but for now there is a workaround:
You can do what sprun.exe does. It invokes winstash.exe
with the names of the TCL files to run, but it also sets up lots
of environment variables and library paths. It also used to
install fonts at runtime, but we don't do that anymore.
The path must contain the $ROOT\lib\windows-binaries and
where $ROOT is the installation directory. The following environment
variables must also be setup:
A TEMP environment variable must also exist, and for the help system
to work, the SystemRoot environment variable must be passed over
Another thing which might be helpful on NT based systems is to run
sprun.exe with the -c switch to start the console. This console has
everything setup, so you can run winstash from there with the
name of the tcl file. You can also look at this to see exactly what
sprun.exe does to the environment. Beware that the console doesn't
work on 9x systems because the command shell is broken.
"Darren Jackson" <darren.jackson at thermolasystems.com> wrote in message
news:3be6bcef$1_1 at nnrp1.news.uk.psi.net...
> I have been attempting to interface to the latest Windows release of the
> Staden Package (2001.0).
> In particular, I am attempting to call Trev with multiple sequence files
> from Visual Basic, by making a call to the Windows API function
> 'ShellExecute' and passing the appropriate parameters as follows:
> ShellExecute(Scr_hDC, "Open", strSprunPath, strParameters, "",
> Where strSprunPath holds a string containing the path to Sprun.exe and
> strParameters holds a string such as
> My problem is that, beyond a certain number of sequence files, Sprun.exe
> crashes with an Access Violation Exception. This does not seem to be
> to the length of the string parameter that is passed, as I have
> with various values. I notice that the number of files that may be safely
> passed seems to have increased since the previous Beta version of the
> Has anybody else encountered this kind of situation?
> Has anybody any suggestions as to the cause or possible remedy?
> Any help will be much appreciated.
More information about the Staden