Soren - 2008-10-16

i can run "testAS511.exe" in the win directory with success.
So i know that my connection and my cable to the PLC is ok.

But if i use my own code:
fds.rfd = setPort(COM1,9600,69) returns OK                   di = New daveInterface(fds,IF1,0,20,2) returns OK            Dim res As Integer = di.initAdapterreturns OK                dc = New daveConnection(di,2,0,0) returns OK                 res = dc.connectPLC()() returns ERROR = -42

Also the NoDaveDemo.exe returns: Error [-21]: no message defined!

Any idear what is wrong?