can flex to call the adwords api?
i use it below, but it doesn't work.
Can someone help me? tks

the code:
<mx:WebService id="Service"
        wsdl="https://adwords.google.com/api/adwords/v12/
KeywordToolService?wsdl"
        useProxy="false" load="setupHeaders()">
        <mx:operation
                name="getKeywordVariations"
                resultFormat="object"
            result="getTrans_result(event);"
            fault="getTrans_fault(event);">
    <mx:request>
    <getKeywordVariations>
      <seedKeywords>
        <negative>false</negative>
        <text>mars cruise</text>
        <type>Broad</type>
      </seedKeywords>
      <useSynonyms>true</useSynonyms>
      <languages>en</languages>
      <countries>US</countries>
    </getKeywordVariations>

   </mx:request>
        </mx:operation>

</mx:WebService>

        public class Info{
            //该类名称可以和.Net中的ValidateSoapHeader不同
            //但字段要对应拼写相同
            public var email:String;
            public var password:String;
            public var clientEmail:String;
            public var useragent:String;

            public var developerToken:String;
            public var applicationToken:String;
        }

private function sendRequest():void{
                var content:Info = new Info();
                content.email = "XXXXXX";
                content.password = "XXXXXX";
                content.clientEmail = "XXXXXX";
                content.useragent = "mogoo inc.: AdWords API Java Sample Code";
                content.developerToken = "XXXXXX";
                content.applicationToken = "XXXXXX";
                var qname:QName = new QName("http://www.w3.org/2001/
XMLSchema","KeywordToolService");
                var header:SOAPHeader = new SOAPHeader(qname,content);

                Service.clearHeaders();
                Service.addHeader(header);
                Service.getKeywordVariations();
        }

<mx:Button   label="发送"   click="sendRequest()"  fontSize="12"/>

tks
what's wrong with it?
Seam


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to 
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/adwords-api?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to