Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / Flash / Flash Remoting / April 2006



Tip: Looking for answers? Try searching our database.

String error???

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
C-Rock - 27 Apr 2006 19:17 GMT
I'm trying to compare a username entered in flash to the username in a
database.

If I have the coldfusion document set-up to take a param "userID" as a numeric
it works fine with flash. If I change it to accept a string and compare it to a
different column in the database that is text, I receive an error. Here is my
code, can anyone tell me why this is happening? Comparing numbers fine but not
strings or text.

CF CODE:

    <cffunction name="getUserDetails" access="remote" returnType="query"
output="true">
    <cfargument name="userID" type="string" required="true">
    <cfquery name="userDetailQuery" datasource="testDataBase">
    SELECT * FROM users WHERE FIRSTNAME = #userID#
    </cfquery>
    <cfreturn userDetailQuery >
    </cffunction>

FLASH CODE:

function getTestConn_Result(re:ResultEvent) {
    //trace(re.result);
    connStatus.text = re.result;
    //Call the Products component
    var userID:String = "Carey";
    getUserDetails(userID);
}
//Handel the Failure
function getTestConn_Fault(fault:FaultEvent):Void {
    trace("error");
}

//Get the Product Details
function getUserDetails(userID) {
    var userDetails_pc:PendingCall = unleashedService.getUserDetails(userID);
    userDetails_pc.responder = new RelayResponder(this, "getUserDetails_Result",
"getUserDetails_Fault");
}

My database has a column set up in it that is called "FIRSTNAME"... Please
help... Thank-you
jag57 - 28 Apr 2006 21:14 GMT
Could you tell us the exact error that occurs?

Have you tried using the NetConnection Debugger?
C-Rock - 28 Apr 2006 21:25 GMT
i think i figured it out... i was having an error with the string from the
database.

my netconnection debugger stops working after a few times and i have to
restart flash to get it to work again... it's very screwy...

thanks for your time though...
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.