Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

SoapConnection - CreateInstance - Invalid proxy name

162 views
Skip to first unread message

CodeJunkie

unread,
Aug 13, 2009, 4:45:24 PM8/13/09
to
Using PB 11.1 - I've created a .Net WebService using VS2008 3.5 .NET
framework, deployed and tested it and it works fine from a C# app.
I've created the WebService project in PB, pointed to the .asmx file
generated by VS, selected the service I want to consume and deployed
this project. The PB WebService DLL has been generated correctly.

Here's my code for consuming the WebService:-

esbAttachmentsWrapper proxy_obj
Long l_returnValue
SoapConnection soapConn
String s_urlEndPoint, s_sharePointFolder,
s_sharePointDocFolder, s_tempFolder = Space (256), s_resultString

GetTempPathA (255, s_tempFolder) //Get the windows temp directory.
soapConn = Create SoapConnection
l_returnValue = soapConn.SetSoapLogFile (s_tempFolder +
"esbAttachmentsWrapperSoapLog.log")
If l_returnValue = 0 Then
Try
l_returnValue = soapConn.CreateInstance (proxy_obj,
"esbAttachmentsWrapper")
If l_returnValue = 0 Then
Try
as_attachment_name = "MES_ID_" + as_mes_id + "_" +
as_attachment_name
If (Not proxy_obj.DownLoadAttachment (s_sharePointFolder,
s_tempFolder, s_sharePointDocFolder, as_attachment_name,
s_resultString)) Then
MessageBox (g_appname, "Error executing DownLoadAttachment
WebService~r~n~r~n" + s_resultString)
Destroy soapConn
Return False
End If
Catch (SoapException e)
MessageBox (g_appname, "Cannot invoke Web service: " +
e.GetMessage ())
Destroy soapConn
Return False
End Try
Else
MessageBox (g_appname, "CreateInstance of WebService Failed: " +
String (l_returnValue) + " - WebService EndPoint URI: " +
s_urlEndPoint)
Destroy soapConn
Return False
End If
Catch (SoapException e1)
MessageBox (g_appName, "SOAP Exception: " + e1.Text)
Catch (PBXRuntimeError e2)
MessageBox (g_appName, "PBX Runtime Error: " + e2.Text)
Catch (RuntimeError e3)
MessageBox (g_appName, "PBX Runtime Error: " + e3.Text)
End Try
Else
MessageBox (g_appname, "SetSoapLogFile Failed: " + String
(l_returnValue) + " - Log file folder: " + s_tempFolder)
Destroy soapConn
Return False
End If
Destroy soapConn


When I run this code from PB everything works fine, but when compile
and run the EXE I get the error 100 (Invalid proxy name) when the
"CreateInstance" is executed.

This is the list of DLL's that I have in the same folder as my EXE and
PBD's

2007-01-22 03:17 PM 89,088 atl71.dll
2007-01-22 03:17 PM 200,704 bputils.dll
2007-01-22 03:17 PM 18,432 CPPSUM32.DLL
2007-10-16 01:01 PM 212,992 EasySoap110.dll
2009-08-13 12:06 PM 9,216 esbAttachmentsWrapper.dll
2007-10-16 01:00 PM 131,072 ExPat110.dll
2007-01-22 03:17 PM 1,703,936 GdiPlus.dll
2007-10-17 03:57 PM 864,256 libeay32.dll
2007-01-22 03:17 PM 356,352 libjcc.dll
2007-01-22 03:17 PM 32,768 libjlog.dll
2007-01-22 03:17 PM 499,712 msvcp71.dll
2007-01-22 03:17 PM 348,160 msvcr71.dll
2007-01-22 03:17 PM 2,965,504 pbdwe100.dll
2007-10-16 02:18 PM 234,872 pbNetWSRuntime110.dll
2007-01-22 03:17 PM 475,136 pbodb100.dll
2007-01-22 03:17 PM 802,816 pbrtc100.dll
2007-01-22 03:17 PM 1,081,344 pbshr100.dll
2007-10-16 01:02 PM 13,824 pbsoapclient110.pbd
2007-10-16 01:01 PM 671,744 pbsoapclient110.pbx
2007-01-22 03:17 PM 50,176 pbtra100.dll
2007-01-22 03:17 PM 4,198,400 pbvm100.dll
2007-10-16 01:02 PM 14,848 pbwsclient110.pbd
2007-10-16 01:02 PM 790,528 pbwsclient110.pbx
2007-01-22 03:18 PM 32,256 pfccom32.dll
2007-10-17 03:57 PM 155,648 ssleay32.dll
2007-10-31 07:29 PM 38,264
Sybase.Powerbuilder.WebService.Runtime.dll
2007-10-31 07:29 PM 173,432
Sybase.PowerBuilder.WebService.RuntimeRemoteLoader.dll
2007-10-31 07:25 PM 30,072
Sybase.PowerBuilder.WebService.WSDL.dll
2007-10-31 07:25 PM 83,320
Sybase.PowerBuilder.WebService.WSDLRemoteLoader.dll
2007-10-17 03:47 PM 2,359,296 xerces-c_2_6.dll
2007-10-17 03:47 PM 278,528 xerces-depdom_2_6.dll

Any help would be appreciated.

Paul Horan[Sybase]

unread,
Aug 14, 2009, 11:34:16 AM8/14/09
to
You'll want to make sure you DON'T have pbsoapclient110.pbd deployed (or in
your target LIB list). That's the EasySoap engine and it will conflict with
the .NET engine, if you have them both deployed. The .NET version is
pbwsclient110.pbd.

Pick one or the other, but not both...

--
Paul Horan[Sybase]
http://blogs.sybase.com/phoran/

"CodeJunkie" <tgc...@yahoo.com> wrote in message
news:36074e6a-335f-4390...@m7g2000prd.googlegroups.com...

CodeJunkie

unread,
Aug 14, 2009, 2:32:24 PM8/14/09
to
Hi Paul,

Thanks for the reply. I tried using your suggestion and still got the
same error, but I think it's due to my PATH statement.

I changed my PATH statement NOT to include the C:\Program Files\Sybase
\Shared\PowerBuilder and now I'm trying to compile the list of runtime
files for PB 11.1

Any suggestions where I could find that list? I've used this link
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.dc37774_1150/html/apptech/BGBEBIEA.htm,
but to no avail.

0 new messages