Topic
  • No replies
Kumarpuneet
Kumarpuneet
1 Post

Pinned topic Issues while Creating PEConnection Using PEWS (.Net)

‏2013-06-22T18:20:07Z |

We are trying to create FileNet Process Engine connection using PE Web Services, for which we have created the web reference of PEWS but unable to make the connection. Below is Code Snippet which we are using for PE Connection. Line at which exception is coming is highlighted in Yellow. Environment Details: FileNet 4.5.1, Visual Studio 2005, WSE 3.0 Public Function PELogin() As Boolean PELogin = False



   
Dim 
tok 
As 
SecurityToken 
   tok 
= 
New 
UsernameToken
(
username
, 
password
, 
PasswordOption
.
SendPlainText
)

    
PEConn 
= 
New 
PERef
.
ProcessEngineServiceWse
() 
   
PEConn
.
Url 
= 
"http://CEServer:9080/wsi/ProcessEngineWS/" 
   
PEConn
.
RequestSoapContext
(
"locale"
) 
= 
"en_US" 
   
PEConn
.
RequestSoapContext
(
"router"
) 
= 
"PEConn2"

    
Dim 
pePolicy 
As 
New 
Policy
(
New 
PolicyAssertion
() 
{
New 
PEAssertion
(), 
New 
PESecurityAssertion
()})

    
PEConn
.
SetPolicy
(
pePolicy
) 
   
UserContext
.
SetProcessSecurityToken
(
tok
)

    
Dim 
g_QInfo 
As 
PERef
.
QueueInfo
() 
   
Try 
       g_QInfo 
= 
PEConn
.
getQueues
        
PELogin 
= 
True 
   
Catch 
wsex 
As 
System
.
Net
.
WebException 
       
MessageBox
.
Show
(
"Web Exception : Login to PE Repository Failed, " 
& 
wsex
.
ToString
, 
wsex
.
Source
.
ToString
) 
   
Catch 
soex 
As 
System
.
Web
.
Services
.
Protocols
.
SoapException 
       
MessageBox
.
Show
(
"Soap Exception : Login to PE Repository Failed, " 
& 
soex
.
ToString
, 
soex
.
Source
.
ToString
) 
   
Catch 
xmlex 
As 
System
.
Xml
.
XmlException 
       
MessageBox
.
Show
(
"Xml Exception : Login to PE Repository Failed, " 
& 
xmlex
.
ToString
, 
xmlex
.
Source
.
ToString
) 
   
Catch 
Ex 
As 
Exception 
       
MessageBox
.
Show
(
"Login to PE Repository Failed " 
& 
ControlChars
.
CrLf 
& 
Ex
.
Message
.
ToString 
& 
" " 
& 
Ex
.
StackTrace
.
ToString
()) 
   
End 
Try
End 
Function

Error Message: System.Net.WebException: The request failed with HTTP status 404: Not Found. at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall) at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)