Re: [flexcoders] Flex / Flash / FlashComm, Remoting and CF

2005-06-09 Thread Indy Nagpal
Yes...

I find that is always a good idea to have a cfm page that queries your
cfc exactly in the same manner as the remoteobject tag in your flex
app would. And use cfdump on your cfm page to examine what the cfc
returns. That way you know exactly what is being returned. And if you
are using structures and queries, be careful of the capitalization of
structure keys and query column names. Trust me, it saves a lot of
time.

Indy

On 6/10/05, dave buhler [EMAIL PROTECTED] wrote:
  Use all Uppers when you reference the remoting object.
  
  I assume you're returning a struct?
  
  If so:
  
  return tempstruct should work fine so long as you have tempstruct.FIRSTNAME
 as the firstname variable name.
  
  If you are returning a query, you'll need to referece result[0].FIRSTNAME,
 etc.
  
  
 
 
 On 6/9/05, Seth Voltz [EMAIL PROTECTED] wrote:
  
  Hey everyone,
  
  A while back someone posted an article on quirks when using Remoting
  (and the flash gateway) with Flex / Flash and FlashComm. I can't find
  it anywhere (archive searches, google, etc.) Maybe I'm just not hitting 
  the right terms.
  
  If anyone remembers it I'd most appreciate the link.
  
  If not, here's the problem I'm having which I think that ink will solve
  (Off Topic):
  
  I have an FCS app which hits a CF7 server's flash gateway looking for a 
  service. The services which return strings work just fine but anything
  that returns something more complex doesn't seem to work. I try
  return.VAR, return.var, return.Var, etc. but it comes back 
  undefined.
  
  Thanks,
  Seth
  
  
  
  
  Yahoo! Groups Links
  
  
  
  
  
  
  
 
  
  
  Yahoo! Groups Links
  
  
 To visit your group on the web, go to:
 http://groups.yahoo.com/group/flexcoders/
   
 To unsubscribe from this group, send an email to:
 [EMAIL PROTECTED]
   
 Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 





Re: [flexcoders] CFlogin, SetCredentials and the RemoteObject

2005-05-26 Thread Indy Nagpal
Have you looked at creating named remoteobjects? That way even though
the methods might be visible in the decompiler, but path to the actual
cfc won't be.

Hmm... regarding your swf file finally being part of cfm page... I've
find myself more comfortable with standalone flex apps (that
interact with CF through remoteobject) rather and flex apps embedded
in cfm pages. I find debugging quite painful when a flex app is embbed
in a cfm page.

Indy

On 5/27/05, dave buhler [EMAIL PROTECTED] wrote:
  I was debating if I should have my login page exist within HTML or as a
 sep., stand alone MXML page.
  
  I mention it because I'm pretty sure the CFC method names and service names
 would be visible to a decompiler and thus, visible to any user who stumbles
 across the Flex Admin system or has just simple access to the Login screen,
 if the login is part of the overall Admin SWF.
  
  Ultimately, my MXML will be a CFM page and I was going to only show the
 Flex SWF if the session is valid, otherwise, kick them back to the sep.
 login page.
  
  Any thoughts?
  
  Dave
 
 
 On 5/25/05, Indy Nagpal [EMAIL PROTECTED] wrote:
  
  Hi Dave:
  
  Here is my setup, I don't know if this helps.
  
  I have a CF application where users need to login. Once they
  successfully plug in their username and password, their session is
  setup (I'm using jessionid). I have a cfc (with relevant functions for 
  login/logout) that is used for authenticating users and setting up
  session.
  
  I call that cfc as remoteobject, firing the login function in the cfc,
  passing it the username and password. If the login is successful, the 
  session for the user is setup and all is sweet. I can access the
  user's session info through the same cfc (i have a function that
  returns their session structure Flex. And my Flex code can then look
  at the session object of the user and do what it needs to. 
  
  I think the key for you would be to get jsessionid going, along with
  using functions within a cfc to validate the user and return user's
  session (or any other value that you want to return to flex).
  
  Indy 
  
  
  
  
  On 5/26/05, dave buhler [EMAIL PROTECTED] wrote:
Hi Indy,
  
I understand setting up perhaps the username and password as a session 
   variable.
  
Can you show me an example of how you are passing over the username and
   password in the remote object? I can see adding it as something like the
   following on each request: 
  
service.getKittens(loginVO,kittensVO)
  
...but was wondering if there was another method that is used directly
 with
   the remote object configuration.
  
Dave
  
   On 5/24/05, Indy Nagpal [EMAIL PROTECTED] wrote:
Hi Dave:
   
I've never tried using RemoteObject with cflogin, but RemoteObject
works very nicely with CF session variables, so it should be able to 
pass that information to your application. To get it to work with
session variables, I was using CF and Flex on the same server, and had
turned on jsessionid (in CF Admin).

Indy
   
On 5/23/05, dave buhler [EMAIL PROTECTED]  wrote:
  Does the RemoteObject permit the passing of a username and password
 to 
   a
 CFLogin tag? I want to create an instance of NetConnection and
 include
 setCredentials(username,password) to pass over to
 my
   remote
 object for a valid user check on each request. If it's not supported
 in 
 Flex, does anyone have any suggestions so that we can ensure a valid
 username and password is part of each remote CFC request.

  Best,
   mx.controls.Alert.show('Dave')

  
  Yahoo! Groups Links


 To visit your group on the web, go to: 
 http://groups.yahoo.com/group/flexcoders/

 To unsubscribe from this group, send an email to:
 [EMAIL PROTECTED]

 Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
   

   
Yahoo! Groups Links
   
   
   
   
   
   
   
  
  

Yahoo! Groups Links 
  
  
   To visit your group on the web, go to:
   http://groups.yahoo.com/group/flexcoders/
  
   To unsubscribe from this group, send an email to: 
   [EMAIL PROTECTED]
  
   Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
  
  
  
  Yahoo! Groups Links 
  
  
  
  
  
  
  
 
  
  
  Yahoo! Groups Links
  
  
 To visit your group on the web, go to:
 http://groups.yahoo.com/group/flexcoders/
   
 To unsubscribe from this group, send an email to:
 [EMAIL PROTECTED]
   
 Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 




Re: [flexcoders] CFlogin, SetCredentials and the RemoteObject

2005-05-25 Thread Indy Nagpal
Hi Dave:

I've never tried using RemoteObject with cflogin, but RemoteObject
works very nicely with CF session variables, so it should be able to
pass that information to your application. To get it to work with
session variables, I was using CF and Flex on the same server, and had
turned on jsessionid (in CF Admin).

Indy

On 5/23/05, dave buhler [EMAIL PROTECTED] wrote:
  Does the RemoteObject permit the passing of a username and password to a
 CFLogin tag? I want to create an instance of NetConnection and include
 setCredentials(username,password) to pass over to my remote
 object for a valid user check on each request. If it's not supported in
 Flex, does anyone have any suggestions so that we can ensure a valid
 username and password is part of each remote CFC request.
  
  Best,
  mx.controls.Alert.show('Dave')
  
  
  Yahoo! Groups Links
  
  
 To visit your group on the web, go to:
 http://groups.yahoo.com/group/flexcoders/
   
 To unsubscribe from this group, send an email to:
 [EMAIL PROTECTED]
   
 Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 




Re: [flexcoders] CFlogin, SetCredentials and the RemoteObject

2005-05-25 Thread Indy Nagpal
Hi Dave:

Here is my setup, I don't know if this helps.

I have a CF application where users need to login. Once they
successfully plug in their username and password, their session is
setup (I'm using jessionid). I have a cfc (with relevant functions for
login/logout) that is used for authenticating users and setting up
session.

I call that cfc as remoteobject, firing the login function in the cfc,
passing it the username and password. If the login is successful, the
session for the user is setup and all is sweet. I can access the
user's session info through the same cfc (i have a function that
returns their session structure Flex. And my Flex code can then look
at the session object of the user and do what it needs to.

I think the key for you would be to get jsessionid going, along with
using functions within a cfc to validate the user and return user's
session (or any other value that you want to return to flex).

Indy




On 5/26/05, dave buhler [EMAIL PROTECTED] wrote:
  Hi Indy,
  
  I understand setting up perhaps the username and password as a session
 variable.
  
  Can you show me an example of how you are passing over the username and
 password in the remote object? I can see adding it as something like the
 following on each request:
  
  service.getKittens(loginVO,kittensVO)
  
  ...but was wondering if there was another method that is used directly with
 the remote object configuration.
  
  Dave
 
 On 5/24/05, Indy Nagpal [EMAIL PROTECTED] wrote:
  Hi Dave:
  
  I've never tried using RemoteObject with cflogin, but RemoteObject
  works very nicely with CF session variables, so it should be able to
  pass that information to your application. To get it to work with 
  session variables, I was using CF and Flex on the same server, and had
  turned on jsessionid (in CF Admin).
  
  Indy
  
  On 5/23/05, dave buhler [EMAIL PROTECTED]  wrote:
Does the RemoteObject permit the passing of a username and password to
 a
   CFLogin tag? I want to create an instance of NetConnection and include
   setCredentials(username,password) to pass over to my
 remote 
   object for a valid user check on each request. If it's not supported in
   Flex, does anyone have any suggestions so that we can ensure a valid
   username and password is part of each remote CFC request. 
  
Best,
mx.controls.Alert.show('Dave')
  

Yahoo! Groups Links
  
  
   To visit your group on the web, go to:
   http://groups.yahoo.com/group/flexcoders/
  
   To unsubscribe from this group, send an email to:
   [EMAIL PROTECTED]
  
   Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
  
  
  
  Yahoo! Groups Links
  
  
  
  
  
  
  
 
  
  
  Yahoo! Groups Links
  
  
 To visit your group on the web, go to:
 http://groups.yahoo.com/group/flexcoders/
   
 To unsubscribe from this group, send an email to:
 [EMAIL PROTECTED]
   
 Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 




Re: [flexcoders] Web Services and CF7

2005-05-19 Thread Indy Nagpal
Hi Ted:

I agree with Andrew totally. Using remoteobject to invoke the cfc on
the server is a much more efficient. I've been using remoteobject to
access cfc and it works beautifully.

A question for you: Are you going to be running cf7 and flex on the
same jrun instance?

If you are, keep in mind the following:

1. Remove the flash remoting gateway that is installed by default with
cf7 (through jrun admin).

2. Make sure that in the flex-config.xml, you have the following value
setup for the amf-gateway (under remote-object node).

amf-gateway{context.root}/amfgateway/amf-gateway

3. When calling the remote object (cfc), make sure to add the correct
endpoint (in the example code below). So, for example, if you were
going to call a cfc called foo with the path myfolder/folder/foo.cfc,
you'd use the following call:

mx:RemoteObject id=myService source=myfolder.folder.foo
endpoint=@ContextRoot()/flashservices/gateway
/mx:RemoteObject

Hope this helps.

Indy

On 5/19/05, Andrew Muller [EMAIL PROTECTED] wrote:
 Ted
 
 Is there any reason, since you're using CF7, why you wouldn't connect
 from Flex via Flash Remoting instead of Web Services, you'd be
 consuming the same CFC presumably and the data should be much less
 verbose...
 
 
 Andrew
 
 Andrew Muller
 Partner, RocketBoots
 http://www.rocketboots.com.au
 
 On 5/19/05, Theodore E Patrick [EMAIL PROTECTED] wrote:
   I am looking at using CF7 and CFC web services with Flex 1.5. I understand
   that some have seen issues with using these two togther or was this limited
   to CF6?
 
   Can anyone highlight the issue for me?
 
   Any help would be most appreciated.
 
   Cheers,
 
   Ted Patrick
 
 
   
   Yahoo! Groups Links
 
  To visit your group on the web, go to:
  http://groups.yahoo.com/group/flexcoders/
 
  To unsubscribe from this group, send an email to:
  [EMAIL PROTECTED]
 
  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
 
 
 
 Yahoo! Groups Links
 
 
 
 
 
 



 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 




Re: [flexcoders] Web Services and CF7

2005-05-19 Thread Indy Nagpal
Ted, I just found another reason why I'd prefer remoteobject over webservices.

If a cfc extends another component, you cannot access the inherited
functions when using webservices. You will have specifically write
functions in the cfc you are calling to expsore the inherited
functions.

However, when you use remoteobject to access a cfc, you can access
inherited functions without needing to expose them..

Indy

On 5/19/05, Indy Nagpal [EMAIL PROTECTED] wrote:
 Hi Ted:
 
 I agree with Andrew totally. Using remoteobject to invoke the cfc on
 the server is a much more efficient. I've been using remoteobject to
 access cfc and it works beautifully.
 
 A question for you: Are you going to be running cf7 and flex on the
 same jrun instance?
 
 If you are, keep in mind the following:
 
 1. Remove the flash remoting gateway that is installed by default with
 cf7 (through jrun admin).
 
 2. Make sure that in the flex-config.xml, you have the following value
 setup for the amf-gateway (under remote-object node).
 
 amf-gateway{context.root}/amfgateway/amf-gateway
 
 3. When calling the remote object (cfc), make sure to add the correct
 endpoint (in the example code below). So, for example, if you were
 going to call a cfc called foo with the path myfolder/folder/foo.cfc,
 you'd use the following call:
 
 mx:RemoteObject id=myService source=myfolder.folder.foo
 endpoint=@ContextRoot()/flashservices/gateway
 /mx:RemoteObject
 
 Hope this helps.
 
 Indy
 
 On 5/19/05, Andrew Muller [EMAIL PROTECTED] wrote:
  Ted
 
  Is there any reason, since you're using CF7, why you wouldn't connect
  from Flex via Flash Remoting instead of Web Services, you'd be
  consuming the same CFC presumably and the data should be much less
  verbose...
 
 
  Andrew
 
  Andrew Muller
  Partner, RocketBoots
  http://www.rocketboots.com.au
 
  On 5/19/05, Theodore E Patrick [EMAIL PROTECTED] wrote:
I am looking at using CF7 and CFC web services with Flex 1.5. I 
   understand
that some have seen issues with using these two togther or was this 
   limited
to CF6?
  
Can anyone highlight the issue for me?
  
Any help would be most appreciated.
  
Cheers,
  
Ted Patrick
  
  

Yahoo! Groups Links
  
   To visit your group on the web, go to:
   http://groups.yahoo.com/group/flexcoders/
  
   To unsubscribe from this group, send an email to:
   [EMAIL PROTECTED]
  
   Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
 
 
 
  Yahoo! Groups Links
 
 
 
 
 
 
 



 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 




Re: [flexcoders] XML vs Model?

2005-05-17 Thread Indy Nagpal
Performance-wise I find that both to be equivalent. But mx:Model
provides a much easier way to access nodes of an xml document (and
most of the times, the easier, the better!). But I agree with Matt's
observation that mx:XML serves a better dataProvider for the Tree
control.

Indy

On 5/18/05, Tracy Spratt [EMAIL PROTECTED] wrote:
 One of my issues with Model is I had trouble determining how the xml was
 going to be deserialized into the object.  What happens to attributes?
 What happens to child nodes and text nodes?
 
 Since I was comfortable with xml I mostly stuck with that.  I haven't
 even needed the available Xpath library yet.  And I hear that improved
 XML support is on the way.
 Tracy
 
 -Original Message-
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Abdul Qabiz
 Sent: Tuesday, May 17, 2005 6:08 AM
 To: flexcoders@yahoogroups.com
 Subject: RE: [flexcoders] XML vs Model?
 
 They are similar things IMO. If you specify a source file for XML or
 Model
 tag, source (xml)file is compiled into swf. So no loading on runtime but
 a
 large initial swf size. P
 
 I think, Model should be good at performance because it is simple Object
 not
 a XMLNode.
 
 Let's see, what other people say...
 
 -abdul
 
 -Original Message-
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Scott Barnes
 Sent: Tuesday, May 17, 2005 12:03 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] XML vs Model?
 
 I've got a external source that pulls in XML file (config).
 
 Now, I'm having my own internal debate as to which of the two is
 betterere?
 
 I've noticed no real signficant performance gains (via profiler) with
 using either, the only thing it kind of brings to the table is that
 you can access a node XYZ levels deep by using property chains
 (parent.child.infant.siblings).
 
 Thats fine, but this will be parsed once-off, and i've found that i've
 i go the XML route (ie writing my own specific parser, it tends to be
 less work.
 
 (in that i've found that you have nodes in your XML that are using the
 same name, but can be either 1 or more, you have to test to see if the
 node in question is an array, otherwise its a literal object and treat
 it as such - when using model vs childNodes approach via XML (which is
 always array).
 
 What's folks here input on pro's / con's of XML vs Model?
 --
 Regards,
 Scott Barnes
 http://www.mossyblog.com
 http://www.flexcoder.com
 
 Yahoo! Groups Links
 
 Yahoo! Groups Links
 
 
 Yahoo! Groups Links
 
 
 
 



 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/