shafiur
2009-03-19 22:15:24 UTC
How do I call this webservice?
I am trying to call using this code but it displays an error:?
Please help me.....
ACtual webservice
<cffunction name="getWebProfileHTML" access="remote" output="false"
returntype="string" displayname="getWebProfileHTML">
<cfargument name="passedStruct" required="false">
<cfset var return = "">
<cfif structKeyExists(arguments.passedStruct,"submit")>
<cfset request.credentials.username = arguments.passedStruct.username>
<cfset request.credentials.applicationToLogin =
arguments.passedStruct.applicationToLogin>
-----------
-------------
</cffunction
--------------------------------------------------------------------------------
----
Code to call webservice:
<cfset passedStruct = StructNew()>
<cfset a = StructInsert(passedStruct, "submit", "submit", 1)>
<cfset a = StructInsert(passedStruct, "username", "***@yahoo.com", 1)>
<cfset a = StructInsert(passedStruct, "applicationToLogin", "atccWeb", 1)>
<!---<cfset passedStruct.username ="***@yahoo.com">
<cfset passedStruct.applicationToLogin="atccWeb">--->
<cfoutput>#passedStruct["submit"]#</cfoutput>
<cfinvoke webservice="http://localhost:8500/library/BaseConsole.cfc?wsdl"
method="getWebProfileHTML"
argumentcollection="#passedStruct#"
returnvariable="profilehtml">
</cfinvoke>
<cfoutput>#profilehtml#</cfoutput>
-------------------------------------------------------------------
Error displayed
Web service operation getWebProfileHTML with parameters
{username={***@yahoo.com},submit={submit},applicationToLogin={atccWeb}}
cannot be found.
The error occurred in C:\ColdFusion8\wwwroot\selfprojects\webservices1.cfm:
line 19
17 : method="getWebProfileHTML"
18 : argumentcollection="#passedStruct#"
19 : returnvariable="profilehtml">
20 : </cfinvoke>
21 : <cfoutput>#profilehtml#</cfoutput>
I am trying to call using this code but it displays an error:?
Please help me.....
ACtual webservice
<cffunction name="getWebProfileHTML" access="remote" output="false"
returntype="string" displayname="getWebProfileHTML">
<cfargument name="passedStruct" required="false">
<cfset var return = "">
<cfif structKeyExists(arguments.passedStruct,"submit")>
<cfset request.credentials.username = arguments.passedStruct.username>
<cfset request.credentials.applicationToLogin =
arguments.passedStruct.applicationToLogin>
-----------
-------------
</cffunction
--------------------------------------------------------------------------------
----
Code to call webservice:
<cfset passedStruct = StructNew()>
<cfset a = StructInsert(passedStruct, "submit", "submit", 1)>
<cfset a = StructInsert(passedStruct, "username", "***@yahoo.com", 1)>
<cfset a = StructInsert(passedStruct, "applicationToLogin", "atccWeb", 1)>
<!---<cfset passedStruct.username ="***@yahoo.com">
<cfset passedStruct.applicationToLogin="atccWeb">--->
<cfoutput>#passedStruct["submit"]#</cfoutput>
<cfinvoke webservice="http://localhost:8500/library/BaseConsole.cfc?wsdl"
method="getWebProfileHTML"
argumentcollection="#passedStruct#"
returnvariable="profilehtml">
</cfinvoke>
<cfoutput>#profilehtml#</cfoutput>
-------------------------------------------------------------------
Error displayed
Web service operation getWebProfileHTML with parameters
{username={***@yahoo.com},submit={submit},applicationToLogin={atccWeb}}
cannot be found.
The error occurred in C:\ColdFusion8\wwwroot\selfprojects\webservices1.cfm:
line 19
17 : method="getWebProfileHTML"
18 : argumentcollection="#passedStruct#"
19 : returnvariable="profilehtml">
20 : </cfinvoke>
21 : <cfoutput>#profilehtml#</cfoutput>