Here is the start of the CFC function
    <cffunction name="get_tech_search" access="remote" returntype="array">
        <cfargument name="before" type="string">
        <cfargument name="after" type="string">
        <cfargument name="innovators" type="array">

I tried the change on the variables and nothing.

I then replaced the variables I was sending with '' and in the cfc made innovators a string vs array and still got the error message.
Peter Farland wrote:
I could probably solve your JRun errors too if you posted them... but that aside, I can help you turn on server side tracing for the CFMX 7 version of the gateway.... what you need to do is look out for the gateway-config.xml file that is specific to the gateway that you're calling. It might be under:
 
/WEB-INF/coldfusion/gateway-config.xml
 
I believe the servlet that's mapped to /flashservices will have an init param in /WEB-INF/web.xml that points you to the location of the configuration file that the gateway is using.
 
Anyway, in this file you'd set the logger to debug:
 
<logger level="Debug">(whatever gateway logger implementation CF uses would be listed here... I think it was coldfusion.flash.ColdFusionLogger if I remember correctly)</logger>
 
You should then be able to look at the log to see a dump of the AMF traffic that went through the gateway's serializer... this might give you a clue as to which parameters are being sent to your CFC method.
 
I think CFMX 7 redirects log info to a flash.log. If you started JRun from the command line and wanted to just see this info on the console you could always switch to use the DefaultLogger:
 
<logger level="Error">flashgateway.log.DefaultLogger</logger>
 
 
Also, I'd still like to look at the <cffunction> and <cfargument> tag signatures for your CFC method....
 
 
In any case, can you try this instead:
 
var otd_tech_after_db:String = "";
var otd_tech_before_db:String = "";
 
If it's not that, can you try narrowing down which attribute is causing it in the call (i.e. by sending null or something you know is a primitive type or a structure that could not possibly contain non-primitive types for the aforementioned Boolean, String or Class types... i.e. don't necessarily trust an API to return you a primitive until you've tracked down the cause)?
 
 


From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf Of Greg Johnson
Sent: Thursday, September 29, 2005 11:22 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Calls to CFCs

I tried to set that once and started getting J-Run errors.  We are running MX7.

I am not exactly doing that.  The related code that is run when that message shows up is below where Person_List is a datagrid, and otd_tech_after_db is empty at the time of the cfc call

var otd_tech_after_db:String = new String();
var otd_tech_before_db:String = new String();

function initFunction() {
    MainNavigation.visible=false;
    Selections.visible=false;
    otd_tech_before_db = getToday();
}

function getToday():String {
    var today_date:Date = new Date();
    var date_str:String = ((today_date.getMonth()+1)+"/"+today_date.getDate()+"/"+today_date.getFullYear());
    return date_str;
}

private function getTechSearch():Void {
        mr_cfc.get_tech_search(otd_tech_before_db, otd_tech_after_db, getPIDs());
}

private function getPIDs():Array {
     var SelectionPIDs:Array = new Array();
     for (var i=0; i<Person_List.length; i++) {
         SelectionPIDs[i] = Person_List.dataProvider[i].PERSON_ID;
     }
     return SelectionPIDs;
}

private function doResultGetTechSearch(result:Array):Void {
    var TempObject:Object = new Object();
    var GetTechSearchArray:Array = new Array();
    for(var i=0; i < result.length; i++){
     TempObject = result[i];
     GetTechSearchArray.push(TempObject);
    }
    OTD_TECH_RESULTS.dataProvider = GetTechSearchArray;
}




Peter Farland wrote:
Are you setting remote-objects-debug in flex-config.xml? What version of ColdFusion are you using?
 
Re: the unsupported type in stream message... are you doing anything like the following:
 
var s:String = new String("foo");
var b:Boolean = new Boolean(true);
var n:Number = new Number(4);
 
Unfortunately in AS1/AS2 the Flash Player does not recognize the Object form of String, Boolean or Number type for serialization purposes so it sends them (yes, oddly) as an unsupported type when serialized as AMF which the remoting gateway rejects. If you use the "primitive" forms of these types in ActionScript:
 
var s:String = "foo";
var b:Boolean = true;
var n:Number = 4;
 
It should work fine.
 
Out of curiosity, how are you generating the data that is sent to the CFC? Are you loading a web service first by any chance and then trying to send that result to a CFC via remote object?
 
Can you post the <cffunction> and accompanying <cfargument> tags from your CFC method that you're invoking? Can you also post the ActionScript line you're using to call the RemoteObject abstraction of your CFC?
 
Thanks,
   Pete
 
 
 






As a professional in computers, I personaly recommend Avast Antivirus
avast! Antivirus: Inbound message clean.

Virus Database (VPS): 0539-2, 09/29/2005
Tested on: 9/29/2005 12:09:15 PM
avast! - copyright (c) 2000-2004 ALWIL Software.



-- 
Greg Johnson
Owner & Lead Technician
[EMAIL PROTECTED]

Techno-Fix-It
Filling the Gap Between the Store and the Repair Shop
----------------------
www.technofixit.com
Phone:(919)-371-1476
Fax:(919)-882-9804
P.O. Box 1094
Morrisville, N.C. 27560


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com




YAHOO! GROUPS LINKS




Reply via email to