I'm having trouble linking a ".lib" file with its associated custom ".dll" files when the .dll is located in a folder other than the executable folder in PSCAD 4.5.3. When the dll is placed in the same folder as the project executable (i.e. "project.if9" directory) I don't have any problems and the simulation runs fine. However, the .if9 folder is routinely flushed during clean builds and I have to recopy the files. When I place the dlls in another folder, referred to by the PATH variable, I cannot run the simulation. See below for more details.
Are there some workspace modifications I need to make? Could anyone provide any insight into this issue?
Thanks for your help!
I've followed the instructions from the PSCAD help:"Location of the *. dll File: The dynamic link library file must be placed either in the same folder as the project executable, or preferably in a directory pointed to by a PATH variable. For example, create a directory called C:\temp\my_dlls and place your *. dll files within it. Then add a PATH environment variable with variable value C:\temp\my_dlls (i.e. points to this directory)."
However, after doing the above I get the following error message in PSCAD:The simulation is no longer responding and may have and unexpected disconnect. This can be due to forced termination or break in communications.Review the exception details?
And reviewing the exception details shows the following:The socket buffer was unable to send data using the current device. There may be an unexpected disconnect blocking the send. Winsock Error = 10054
Looking up the Winsock documentation, the following is determined:WSAECONNRESET
- Connection reset by peer.
An existing connection was forcibly closed by the remote host. This normally results if the peer application on the remote host is suddenly stopped, the host is rebooted, the host or remote network interface is disabled, or the remote host uses a hard close (see setsockopt for more information on the SO_LINGER option on the remote socket). This error may also result if a connection was broken due to keep-alive activity detecting a failure while one or more operations are in progress. Operations that were in progress fail with WSAENETRESET. Subsequent operations fail with WSAECONNRESET.