Flash 2004 Remoting

2005-04-11 Thread Greg Johnson
Can anyone point me to a good source on the web to see some actual code 
on how to do this.  Been following the stuff in the official referance 
and have some 2004 books on order, but what I am trying just aint 
working.  I have a cfc located in the gateway/cfc directory with the 
contents of

> 
>  displayname="Return House" hint="This returns a list of Legislators in 
> the house.">
> 
> 
> SELECT nvc_leg_name
> FROM dbo.tbl_leg
> WHERE (int_leg_house_senate = 1);
> 
> 
> 
>
> 
> 

and put this in the first frame of my flash app

> //Import Classes
> import mx.remoting.Service;
> import mx.remoting.PendingCall;
> import mx.rpc.RelayResponder;
> import mx.rpc.ResultEvent;
> import mx.rpc.FaultEvent;
>
> //Create ReplayResponder to specify result handling methods
> var myResponder:RelayResponder = new 
> RelayResponder(this,"returnhouse_Result","returnhouse_Fault");
>
> //establish gateway and create a Service object to refer to the service
> var CFMService:Service = new 
> Service("http://localhost:8500/flashservices/gateway",null,"legislators",null,null);
>
> //set user credentials
> CFMService.connection.setCredentials("cfa","cfa");
>
> //call service function
> var temp_pc:PendingCall = CFMService.returnhouse();
> trace("call made");
>
> //Result Handler
> function returnhouse_Result (re:ResultEvent):Void {
> trace("Worked");
> }
>
> //Fault Handler
> function returnhouse_Fault (fe:FaultEvent):Void {
> trace("Failed");
> }

When I run it the output gives me the /*call made*/ and no errors, but 
thats it.  No /*worked */or /*failed*/. :'(

-- 
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



~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:202177
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Flash 2004 Remoting

2005-04-11 Thread Kevin Aebig
Hey greg,

I think you're making this a bit more complicated than need be. Are you
using roles authentication? If so, you'll need to set the remote method to
have the proper authority. If not, than you're setting the credentials for
no reason.

I have an example of roles authentication remoting at home that I can post
if thats your intention.

Cheers,

Kevin

--
http://www.keslabs.com

Coldfusion Remote Dashboard ::
http://www.keslabs.com/crd

-Original Message-
From: Greg Johnson [mailto:[EMAIL PROTECTED]
Sent: Monday, April 11, 2005 9:37 AM
To: CF-Talk
Subject: Flash 2004 Remoting


Can anyone point me to a good source on the web to see some actual code
on how to do this.  Been following the stuff in the official referance
and have some 2004 books on order, but what I am trying just aint
working.  I have a cfc located in the gateway/cfc directory with the
contents of

> 
>  displayname="Return House" hint="This returns a list of Legislators in
> the house.">
>
> 
> SELECT nvc_leg_name
> FROM dbo.tbl_leg
> WHERE (int_leg_house_senate = 1);
> 
> 
> 
>
> 
> 

and put this in the first frame of my flash app

> //Import Classes
> import mx.remoting.Service;
> import mx.remoting.PendingCall;
> import mx.rpc.RelayResponder;
> import mx.rpc.ResultEvent;
> import mx.rpc.FaultEvent;
>
> //Create ReplayResponder to specify result handling methods
> var myResponder:RelayResponder = new
> RelayResponder(this,"returnhouse_Result","returnhouse_Fault");
>
> //establish gateway and create a Service object to refer to the service
> var CFMService:Service = new
>
Service("http://localhost:8500/flashservices/gateway",null,"legislators",nul
l,null);
>
> //set user credentials
> CFMService.connection.setCredentials("cfa","cfa");
>
> //call service function
> var temp_pc:PendingCall = CFMService.returnhouse();
> trace("call made");
>
> //Result Handler
> function returnhouse_Result (re:ResultEvent):Void {
> trace("Worked");
> }
>
> //Fault Handler
> function returnhouse_Fault (fe:FaultEvent):Void {
> trace("Failed");
> }

When I run it the output gives me the /*call made*/ and no errors, but
thats it.  No /*worked */or /*failed*/. :'(

--
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





~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:202197
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


Re: Flash 2004 Remoting

2005-04-11 Thread Greg Johnson
Nope.  I am just trying to do a very simple system where it retrieves a 
list of names (to start with) and displays them in a list box.  Once I 
do that I will make it so clicking on a name will bring up a 2ed window 
that will give detailed info on the person.



Kevin Aebig wrote:

>Hey greg,
>
>I think you're making this a bit more complicated than need be. Are you
>using roles authentication? If so, you'll need to set the remote method to
>have the proper authority. If not, than you're setting the credentials for
>no reason.
>
>I have an example of roles authentication remoting at home that I can post
>if thats your intention.
>
>Cheers,
>
>Kevin
>
>--
>http://www.keslabs.com
>
>Coldfusion Remote Dashboard ::
>http://www.keslabs.com/crd
>
>-Original Message-
>From: Greg Johnson [mailto:[EMAIL PROTECTED]
>Sent: Monday, April 11, 2005 9:37 AM
>To: CF-Talk
>Subject: Flash 2004 Remoting
>
>
>Can anyone point me to a good source on the web to see some actual code
>on how to do this.  Been following the stuff in the official referance
>and have some 2004 books on order, but what I am trying just aint
>working.  I have a cfc located in the gateway/cfc directory with the
>contents of
>
>  
>
>>
>>>displayname="Return House" hint="This returns a list of Legislators in
>>the house.">
>>
>>
>>SELECT nvc_leg_name
>>FROM dbo.tbl_leg
>>WHERE (int_leg_house_senate = 1);
>>
>>
>>
>>
>>
>>
>>
>>
>
>and put this in the first frame of my flash app
>
>  
>
>>//Import Classes
>>import mx.remoting.Service;
>>import mx.remoting.PendingCall;
>>import mx.rpc.RelayResponder;
>>import mx.rpc.ResultEvent;
>>import mx.rpc.FaultEvent;
>>
>>//Create ReplayResponder to specify result handling methods
>>var myResponder:RelayResponder = new
>>RelayResponder(this,"returnhouse_Result","returnhouse_Fault");
>>
>>//establish gateway and create a Service object to refer to the service
>>var CFMService:Service = new
>>
>>
>>
>Service("http://localhost:8500/flashservices/gateway",null,"legislators",nul
>l,null);
>  
>
>>//set user credentials
>>CFMService.connection.setCredentials("cfa","cfa");
>>
>>//call service function
>>var temp_pc:PendingCall = CFMService.returnhouse();
>>trace("call made");
>>
>>//Result Handler
>>function returnhouse_Result (re:ResultEvent):Void {
>>trace("Worked");
>>}
>>
>>//Fault Handler
>>function returnhouse_Fault (fe:FaultEvent):Void {
>>trace("Failed");
>>}
>>
>>
>
>When I run it the output gives me the /*call made*/ and no errors, but
>thats it.  No /*worked */or /*failed*/. :'(
>
>--
>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
>
>
>
>
>
>

~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:202207
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Flash 2004 Remoting

2005-04-11 Thread Kevin Aebig
Have you tried using the netconnection debugger? It will show you where the
call is failing as well as any errors being posted but not handled.

You can find it in FMX2004 under:
The "Windows" Menu > Other Panels > Netconnection Debugger

Sincerely,

Kevin

-Original Message-
From: Greg Johnson [mailto:[EMAIL PROTECTED]
Sent: Monday, April 11, 2005 11:14 AM
To: CF-Talk
Subject: Re: Flash 2004 Remoting


Nope.  I am just trying to do a very simple system where it retrieves a
list of names (to start with) and displays them in a list box.  Once I
do that I will make it so clicking on a name will bring up a 2ed window
that will give detailed info on the person.



Kevin Aebig wrote:

>Hey greg,
>
>I think you're making this a bit more complicated than need be. Are you
>using roles authentication? If so, you'll need to set the remote method to
>have the proper authority. If not, than you're setting the credentials for
>no reason.
>
>I have an example of roles authentication remoting at home that I can post
>if thats your intention.
>
>Cheers,
>
>Kevin
>
>--
>http://www.keslabs.com
>
>Coldfusion Remote Dashboard ::
>http://www.keslabs.com/crd
>
>-Original Message-
>From: Greg Johnson [mailto:[EMAIL PROTECTED]
>Sent: Monday, April 11, 2005 9:37 AM
>To: CF-Talk
>Subject: Flash 2004 Remoting
>
>
>Can anyone point me to a good source on the web to see some actual code
>on how to do this.  Been following the stuff in the official referance
>and have some 2004 books on order, but what I am trying just aint
>working.  I have a cfc located in the gateway/cfc directory with the
>contents of
>
>
>
>>
>>>displayname="Return House" hint="This returns a list of Legislators in
>>the house.">
>>
>>
>>SELECT nvc_leg_name
>>FROM dbo.tbl_leg
>>WHERE (int_leg_house_senate = 1);
>>
>>
>>
>>
>>
>>
>>
>>
>
>and put this in the first frame of my flash app
>
>
>
>>//Import Classes
>>import mx.remoting.Service;
>>import mx.remoting.PendingCall;
>>import mx.rpc.RelayResponder;
>>import mx.rpc.ResultEvent;
>>import mx.rpc.FaultEvent;
>>
>>//Create ReplayResponder to specify result handling methods
>>var myResponder:RelayResponder = new
>>RelayResponder(this,"returnhouse_Result","returnhouse_Fault");
>>
>>//establish gateway and create a Service object to refer to the service
>>var CFMService:Service = new
>>
>>
>>
>Service("http://localhost:8500/flashservices/gateway",null,"legislators",nu
l
>l,null);
>
>
>>//set user credentials
>>CFMService.connection.setCredentials("cfa","cfa");
>>
>>//call service function
>>var temp_pc:PendingCall = CFMService.returnhouse();
>>trace("call made");
>>
>>//Result Handler
>>function returnhouse_Result (re:ResultEvent):Void {
>>trace("Worked");
>>}
>>
>>//Fault Handler
>>function returnhouse_Fault (fe:FaultEvent):Void {
>>trace("Failed");
>>}
>>
>>
>
>When I run it the output gives me the /*call made*/ and no errors, but
>thats it.  No /*worked */or /*failed*/. :'(
>
>--
>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
>
>
>
>
>
>



~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:202226
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


Re: Flash 2004 Remoting

2005-04-11 Thread Greg Johnson
My dumb.  Boss played around with the database, there WAS only 1 record 
to return :-P   Now to try binding :-)  

-- 
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


~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:202234
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


Re: Flash 2004 Remoting

2005-04-11 Thread Greg Johnson
I will try that.  Through "percussive maitenance" of the computer I was 
able to find where I had made a couple of mistakes though and it is now 
connecting.  Unf. thats the problem with scraping sample code off the 
internet, you miss things sometimes.  My big mistake was not adding the 
responder to the connection, thus that prevented it from giving me 
anything.  Once I changed that, I realized I had to change the service 
name to include the dir level it was in and that got me a query error 
which atleast meant I was getting to the cfc.  Fixed that, but now its 
saying it's only returned 1 record vs the list of people I know are in 
there so I am going to look at that and see whats up.

Thanks

Kevin Aebig wrote:

>Have you tried using the netconnection debugger? It will show you where the
>call is failing as well as any errors being posted but not handled.
>
>You can find it in FMX2004 under:
>The "Windows" Menu > Other Panels > Netconnection Debugger
>
>Sincerely,
>
>Kevin
>
>-Original Message-
>From: Greg Johnson [mailto:[EMAIL PROTECTED]
>Sent: Monday, April 11, 2005 11:14 AM
>To: CF-Talk
>Subject: Re: Flash 2004 Remoting
>
>
>Nope.  I am just trying to do a very simple system where it retrieves a
>list of names (to start with) and displays them in a list box.  Once I
>do that I will make it so clicking on a name will bring up a 2ed window
>that will give detailed info on the person.
>
>
>
>Kevin Aebig wrote:
>
>  
>
>>Hey greg,
>>
>>I think you're making this a bit more complicated than need be. Are you
>>using roles authentication? If so, you'll need to set the remote method to
>>have the proper authority. If not, than you're setting the credentials for
>>no reason.
>>
>>I have an example of roles authentication remoting at home that I can post
>>if thats your intention.
>>
>>Cheers,
>>
>>Kevin
>>
>>--
>>http://www.keslabs.com
>>
>>Coldfusion Remote Dashboard ::
>>http://www.keslabs.com/crd
>>
>>-Original Message-
>>From: Greg Johnson [mailto:[EMAIL PROTECTED]
>>Sent: Monday, April 11, 2005 9:37 AM
>>To: CF-Talk
>>Subject: Flash 2004 Remoting
>>
>>
>>Can anyone point me to a good source on the web to see some actual code
>>on how to do this.  Been following the stuff in the official referance
>>and have some 2004 books on order, but what I am trying just aint
>>working.  I have a cfc located in the gateway/cfc directory with the
>>contents of
>>
>>
>>
>>
>>
>>>
>>>   >>displayname="Return House" hint="This returns a list of Legislators in
>>>the house.">
>>>
>>>   
>>>   SELECT nvc_leg_name
>>>   FROM dbo.tbl_leg
>>>   WHERE (int_leg_house_senate = 1);
>>>   
>>>   
>>>   
>>>
>>>   
>>>
>>>
>>>
>>>  
>>>
>>and put this in the first frame of my flash app
>>
>>
>>
>>
>>
>>>//Import Classes
>>>import mx.remoting.Service;
>>>import mx.remoting.PendingCall;
>>>import mx.rpc.RelayResponder;
>>>import mx.rpc.ResultEvent;
>>>import mx.rpc.FaultEvent;
>>>
>>>//Create ReplayResponder to specify result handling methods
>>>var myResponder:RelayResponder = new
>>>RelayResponder(this,"returnhouse_Result","returnhouse_Fault");
>>>
>>>//establish gateway and create a Service object to refer to the service
>>>var CFMService:Service = new
>>>
>>>
>>>
>>>  
>>>
>>Service("http://localhost:8500/flashservices/gateway",null,"legislators",nu
>>
>>
>l
>  
>
>>l,null);
>>
>>
>>
>>
>>>//set user credentials
>>>CFMService.connection.setCredentials("cfa","cfa");
>>>
>>>//call service function
>>>var temp_pc:PendingCall = CFMService.returnhouse();
>>>trace("call made");
>>>
>>>//Result Handler
>>>function returnhouse_Result (re:ResultEvent):Void {
>>>   trace("Worked");
>>>}
>>>
>>>//Fault Handler
>>>function returnhouse_Fault (fe:FaultEvent):Void {
>>>   trace("Failed");
>>>}
>>>
>>>
>>>  
>>>
>>When I run it the output gives me the /*call made*/ and no errors, but
>>thats it.  No /*worked */or /*failed*/. :'(
>>
>>--
>>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
>>
>>
>>
>>
>>
>>
>>
>>
>
>
>
>

~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:202249
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54