Did you check your WSDL file. Are you mapping the objects correctly.

----- Original Message ----
From: nehavyas13 <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Friday, April 4, 2008 11:03:56 AM
Subject: [flexcoders] Unrecognised binding style null

                I am trying to access a webservice method throught action 
Script. I
just need to call a method " RequestSomeMethod" and send 2 parameters.
But am getting following error :

RPC Fault faultString= "Unrecognized binding style 'null'. Only
'document' and 'rpc' styles are supported." faultCode="Encoding Error"
faultDetail= "null"

I am not expecting anything back from the webservice. I just need to
call the method so that it takes some action.

Can please somebody help me with this and tell me why am I getting
this error and how to get rid of it?

In the wsdl file that I am accessing, some of the tags it has are as
below. It does not have style property in soap binding tag, but is in
operation tag. Is that OK? or does flex expect it to be in soap
binding tag and hence give me this error?

Attached is the code I am using for Action Script:

<?xml version="1.0" ?>

<mx:Button xmlns:mx="http://www.adobe. com/2006/ mxml"
click="useWebServic e()" width="80%" >
<mx:Script>

<![CDATA[
import mx.rpc.soap. LoadEvent;

import mx.controls. Alert;
import mx.rpc.http. HTTPService;
import mx.rpc.soap. WebService;
import mx.rpc.events. ResultEvent;
import mx.rpc.events. FaultEvent;

private var ws:WebService;
private var para1:Number;
private var para2:int;

override public function set data(value:Object) :void
{
para1=1;
setStyle("color" , "red");
enabled=false;
label ="Do not click";
para2=0

}

public function useWebService( ):void {
ws = new WebService() ;

ws.addEventListener ("fault", faultHandler) ;
ws.addEventListener (LoadEvent. LOAD,wsLoaded) ;
ws.addEventListener (ResultEvent. RESULT, result_listener) ;
ws.wsdl= "someurl?wsdl" ;
ws.loadWSDL( );

}

private function wsLoaded(loadEvent: Event):void{
ws.RequestSomeMetho d(para1, para2);
}

public function echoResultHandler( event:ResultEven t):void {
Alert.show(" WSDL returned");
}

public function faultHandler( event:FaultEvent ):void {
trace(event. fault);
}

public function result_listener( event:ResultEven t):void {
}

]]>
</mx:Script>

</mx:Button>

WSDL file:

- <wsdl:binding name="abc" type="tns:IJK" >
<wsp:PolicyReferenc e URI="#XYZ" />
<soap12:binding transport="http://schemas. xmlsoap.org/ soap/http" />
- <wsdl:operation name="RequestDetail s">
<soap12:operation soapAction="http://tempuri/ RequestDetails"
style="document" />
- <wsdl:input>
<soap12:body use="literal" />
</wsdl:input>
- <wsdl:output>
<soap12:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>


    
                                
<!--

#ygrp-mkp{
border:1px solid #d8d8d8;font-family:Arial;margin:14px 0px;padding:0px 14px;}
#ygrp-mkp hr{
border:1px solid #d8d8d8;}
#ygrp-mkp #hd{
color:#628c2a;font-size:85%;font-weight:bold;line-height:122%;margin:10px 0px;}
#ygrp-mkp #ads{
margin-bottom:10px;}
#ygrp-mkp .ad{
padding:0 0;}
#ygrp-mkp .ad a{
color:#0000ff;text-decoration:none;}
-->

<!--

#ygrp-sponsor #ygrp-lc{
font-family:Arial;}
#ygrp-sponsor #ygrp-lc #hd{
margin:10px 0px;font-weight:bold;font-size:78%;line-height:122%;}
#ygrp-sponsor #ygrp-lc .ad{
margin-bottom:10px;padding:0 0;}
-->
        
<!--

        #ygrp-mlmsg {font-size:13px;font-family:arial, helvetica, clean, 
sans-serif;}
#ygrp-mlmsg table {font-size:inherit;font:100%;}
#ygrp-mlmsg select, input, textarea {font:99% arial, helvetica, clean, 
sans-serif;}
#ygrp-mlmsg pre, code {font:115% monospace;}
#ygrp-mlmsg * {line-height:1.22em;}
#ygrp-text{
font-family:Georgia;
}
#ygrp-text p{
margin:0 0 1em 0;}
#ygrp-tpmsgs{
font-family:Arial;
clear:both;}
#ygrp-vitnav{
padding-top:10px;font-family:Verdana;font-size:77%;margin:0;}
#ygrp-vitnav a{
padding:0 1px;}
#ygrp-actbar{
clear:both;margin:25px 0;white-space:nowrap;color:#666;text-align:right;}
#ygrp-actbar .left{
float:left;white-space:nowrap;}
.bld{font-weight:bold;}
#ygrp-grft{
font-family:Verdana;font-size:77%;padding:15px 0;}
#ygrp-ft{
font-family:verdana;font-size:77%;border-top:1px solid #666;
padding:5px 0;
}
#ygrp-mlmsg #logo{
padding-bottom:10px;}

#ygrp-reco {
margin-bottom:20px;padding:0px;}
#ygrp-reco #reco-head {
font-weight:bold;color:#ff7900;}

#reco-grpname{
font-weight:bold;margin-top:10px;}
#reco-category{
font-size:77%;}
#reco-desc{
font-size:77%;}

#ygrp-vital{
background-color:#e0ecee;margin-bottom:20px;padding:2px 0 8px 8px;}
#ygrp-vital #vithd{
font-size:77%;font-family:Verdana;font-weight:bold;color:#333;text-transform:uppercase;}
#ygrp-vital ul{
padding:0;margin:2px 0;}
#ygrp-vital ul li{
list-style-type:none;clear:both;border:1px solid #e0ecee;
}
#ygrp-vital ul li .ct{
font-weight:bold;color:#ff7900;float:right;width:2em;text-align:right;padding-right:.5em;}
#ygrp-vital ul li .cat{
font-weight:bold;}
#ygrp-vital a{
text-decoration:none;}

#ygrp-vital a:hover{
text-decoration:underline;}

#ygrp-sponsor #hd{
color:#999;font-size:77%;}
#ygrp-sponsor #ov{
padding:6px 13px;background-color:#e0ecee;margin-bottom:20px;}
#ygrp-sponsor #ov ul{
padding:0 0 0 8px;margin:0;}
#ygrp-sponsor #ov li{
list-style-type:square;padding:6px 0;font-size:77%;}
#ygrp-sponsor #ov li a{
text-decoration:none;font-size:130%;}
#ygrp-sponsor #nc{
background-color:#eee;margin-bottom:20px;padding:0 8px;}
#ygrp-sponsor .ad{
padding:8px 0;}
#ygrp-sponsor .ad #hd1{
font-family:Arial;font-weight:bold;color:#628c2a;font-size:100%;line-height:122%;}
#ygrp-sponsor .ad a{
text-decoration:none;}
#ygrp-sponsor .ad a:hover{
text-decoration:underline;}
#ygrp-sponsor .ad p{
margin:0;}
o{font-size:0;}
.MsoNormal{
margin:0 0 0 0;}
#ygrp-text tt{
font-size:120%;}
blockquote{margin:0 0 0 4px;}
.replbq{margin:4;}
-->
                





      
____________________________________________________________________________________
You rock. That's why Blockbuster's offering you one month of Blockbuster Total 
Access, No Cost.  
http://tc.deals.yahoo.com/tc/blockbuster/text5.com

Reply via email to