I have a couple of programs that do this in VB. Unfortunately they
are coupled into larger programs or have ActiveX components. I may
try to strip out the relevent code "sanitize it", and put it into a
project or two and write up some documentation if I find the time
during the coming weeks.
--- In twsapi@y..., "Michel" <migurull@t...> wrote:
Hi,
Does somebody know some way to run the TWS application unattended?
What I need is:
1- Avoid the login screen, passing parameters (UserName and
Password) from
my calling application.
2- Respond to the message window asking 'Accept incoming connection
attempt?' when I connect to the local server.
This is because I'm writting my own program (Visual Basic using TWS
ActiveX)
which allways runs in the background and want it to automatically
launch TWS
few minutes before markets open and perform some automated tasks
when I'm
not at home.
I've tried to launch TWS from my application with a call
to 'ShellExecute',
passing parameters as 'username' or 'user' without success. I
always get the
login screen blank because I ignore if TWS accepts such parameters
and how
they must be coded (I think this must be possible because in the
web demo,
the login screen appears whith such fields pre-filled with 'edemo'
and
'demouser'). Perhaps in some 'ini' file? (I've not found any
section related
to username and password).
Thanks for any help.
Michel.