User 1abb59587f
29-06-2012 10:36:06
I have just installed Web Services 5.10 on a Windows Server 2008. The Web Services are running on the same machine as SqlSever. I use the following code to try and make the connection (asp.net c#)
The asp.net code is being run from my development machine.(Windows 7)
I set the WebServices up in my app as "Old Style" Web Services I have no problem seeing the WSDL from this machine in the browser. The values I use for driver, URL etc come from my connection to JChem Manager which works fine.. string driver = "com.microsoft.sqlserver.jdbc.SQLServerDriver"; string url = @"jdbc:sqlserver://108.166.6.216:1433;databaseName=CompoundDev;SelectMethod=cursor"; string propertiesTable = "JChemProperties"; string username = ConfigurationManager.AppSettings["username"]; string password = ConfigurationManager.AppSettings["password"]; ConnectionWS connectionWS = new JChemConnectionWebReference.ConnectionWS();
string connection = connectionWS.getConnection(driver, url, username, password, propertiesTable);
When I execute it I get the following error:
"A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 10.134.80.5:8180"}
I don't know where the 10.134.80.5:8180 come from.
If I can get this to work I then need to insert a molecule. Here is the code for that: JChemDataManipulationWebReference.
DataManipulationWS manipulationWS = new JChemDataManipulationWebReference.DataManipulationWS();
string structureId = manipulationWS.addStructure(connection, structureTableName, molecule, null, null);
my question here is the first argument to addStructure is looking for a "connectionHandlerId" is that something different from the connection I plan on passing in?
If anyone has a code snippet of a working example I would grestly appreciate it. As always I am up against a deadline.
Thanks in Advance,
Bob Trucchi