I had this problem about 6 months ago and I don't remember how I solved it. However, here is the code that I currently use to make the connection and return results. Hope it helps.
######################################################################## ######### import mx.remoting.Service; import mx.services.Log; import mx.rpc.RelayResponder; import mx.rpc.FaultEvent; import mx.rpc.ResultEvent; import mx.remoting.PendingCall; import mx.remoting.RecordSet; //#######################SETUP CONNECTION########################### var contactService:Service = new Service( "http://abish.byui.edu/flashservices/gateway?", //"http://localhost:8500/flashservices/gateway?", null, "wsmri.WsmriDate1", null, null); //##################################################################### //######GET RECORDS################################################# function fgetMarriageRecords(fName, lname, strID, searchType, state_Svar, county_Svar, dateLimit, bDate, eDate){ var pc:PendingCall = contactService.getRecordsWDate({FirstName: fName, LastName: lname, strID: strID, searchType: searchType, mState: state_Svar, county: county_Svar, dateLimit: dateLimit, bDate: bDate, eDate: eDate}); var oResult:Object = new Object(); oResult.onResult = function(re:ResultEvent){ var rs:RecordSet = RecordSet(re.result); var nCount:Number = rs.length; recNum_label.text = rs.length; //trace("length is : " + rs.length); //if no results returned show message screen if (rs.length == 0) { noResults1_mc._visible = true;; this.noResults1_mc.ok_btn.setFocus(); } results_dg.dataProvider = rs; results_dg.selectedIndex = 0; searchInProgress1_mc._visible = false; // marker for mouse pointer }; oResult.onFault = function(re:ResultEvent){ //trace("> fault >"); for(var i in re){ //trace(i + " = " + re[i]); for(var j in re[i]){ //trace(j + " = " + re[i][j]); } } }; pc.responder = new RelayResponder(oResult, "onResult", "onFault" ); } ###################END GET RECORDS################################### -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Liam Mincy Sent: Wednesday, November 01, 2006 3:57 AM To: Flashcoders mailing list Subject: [Flashcoders] Flash Reomoting Service not connecting This is a new one for me... I have a Flash application that uses Flash Remoting to pass along test information. I should first mention that I am using the same Service on a live server in both testing on local machine and when I deploy to the web. The thing is that when I test all of this from my local machine it all wowrks well. The test information is passed along the Service, all the data appears in the database, and I get feedback inside of Flash. It is only when I upload Flash to the server that I have no connection at all to the service. The Flash and the Service both sit on the same domain when uploaded. Here is what i have tried: - Made sure that the link to the Service is correct - Installed a crossdomain.xml at the root of the domain with very generous settings - Tried dumping result and fault into onscreen text field but since there is some communication/security issue nothing comes back What I am seeing is that the Flash essentially just runs and runs with no connection or indication that it is getting a fault back. It just keeps trying and nothing is coming back. What has me stumped is why this would happen. Does anyone have any experience with this scenario using Services? Thanks, liam m- ________________________________________________________________________ ____________ Low, Low, Low Rates! Check out Yahoo! Messenger's cheap PC-to-Phone call rates (http://voice.yahoo.com) _______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com _______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com