Expand my Community achievements bar.

WebServices

Avatar

Level 1
Hi,

I was trying an example on Webservices. here is the code.



<?xml version="1.0" encoding="utf-8"?>



<mx:Application



xmlns:mx="
http://www.adobe.com/2006/mxml"
backgroundColor="#FFFFFF">

<mx:WebService



id="srv"
wsdl="https://ngiqtst.qualcomm.com/qwbs/DeptServiceSoapHttpPort?wsdl"
showBusyCursor="true"/>





<mx:DataGrid
dataProvider="{srv.retrieveDepartmentData.lastResult}" >



<mx:columns>



<mx:DataGridColumn dataField="dname"
headerText="DeptName"/>



<mx:DataGridColumn dataField="loc"
headerText="Location"/>



<mx:DataGridColumn dataField="deptno"
headerText="DeptNo"/>



</mx:columns>



</mx:DataGrid>





<mx:Button label="Get Data"
click="srv.retrieveDepartmentData()"/>

</mx:Application>



when the run the application , it gives the following error

[RPC Fault faultString="Security error accessing url"
faultCode="Channel.Security.Error" faultDetail="Unable to load
WSDL. If currently online, please verify the URI and/or format of
the WSDL
(https://ngiqtst.qualcomm.com/qwbs/DeptServiceSoapHttpPort?wsdl)"]

at WSDLParser/dispatchFault()

at WSDLParser/
http://www.adobe.com/2006/flex/mx/internal::httpFaultHandler()

at flash.events::EventDispatcher/dispatchEventFunction()

at flash.events::EventDispatcher/dispatchEvent()

at mx.rpc::AbstractInvoker/
http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent()

at mx.rpc::AbstractInvoker/
http://www.adobe.com/2006/flex/mx/internal::faultHandler()

at mx.rpc::Responder/fault()

at mx.rpc::AsyncRequest/fault()

at DirectHTTPMessageResponder/securityErrorHandler()

at flash.events::EventDispatcher/dispatchEventFunction()

at flash.events::EventDispatcher/dispatchEvent()

at flash.net::URLLoader/redirectEvent()



Can anyone help me out from this ?please

3 Replies

Avatar

Level 1
Hi BVFlex, I had the same problem accessing webservice with
remote method once i publish my webservice.

check if you have posted your websrvice on web or iss, give
the correct path,

check your webservice manully on the browser to check it
works or not that might be be one problem,

every one siad it is problem with crossdomain but i think
that is not the problem

Avatar

Level 1
Hi Ranjit,



Thanks a lot. Atlast a reply from the forum.



Yeah, I have checked the webservice on the browser, it works
fine.



And for the crossdomain, can you please where to place to
cross domain tag in which file?



Avatar

Former Community Member
"By default, place the crossdomain.xml at the root directory
of the server that is serving the data." said in LiveDocs
http://livedocs.adobe.com/flex/3/html/help.html?content=deployingoverview_12.html



If you cannot modify the web service - i.e. add
crossdomain.xml to its deployment, use BlazeDS (
http://opensource.adobe.com/wiki/display/blazeds/BlazeDS).
It is free. It allows you setup a local proxy for a remote web
service.



- Mykola