AMFPHP Flex3 and Cairngorm

Trying to get back into Flex here and I decided to try using
it with PHP. I have set up AMFPHP 1.9beta I created a DataService
class with a getUsers function. I have tested AMFPHP in with the
browser and it creates the User objects properly and returns them.
When calling from Flex I can see that it is hitting the getUsers
function as I add a call that writes to a file to tell me it got
there. I put an Alert.show in the result function and I am not
getting there. I do not have FlexBuilder, so I am not able to
debug. All seems to compile fine and through a series of Alerts I
can see that everything is getting called. Looking for any
suggestions or assistance I can find here.

Hi Mike,
Flex Builder connects to SQL Server through a TCP/IP
connection. This type of connection it might not be enabled for
your server. Please check if this is the case for you (the default
port is 1433).
Regards,
Miti

Similar Messages

  • Help with Flex, Blaze and Cairngorm

    I using Blaze, Flex3 and Cairngorm, I have a simple
    application at the moment, in which I dispatch a Cairngorm event,
    it gets picked up the Command is executed and the Delegate can send
    data to the RemoteObject. I can see in the output that Blaze is
    doing what it is supposed to do and returning what it is supposed
    to return, but the data returned never makes it to the IResponder
    result function. What am I doing wrong? Can post code if
    needed.

    BlazeDS Console is where I am seeing the output. I don't see
    anywhere to attach code so I will put some here, is there any
    particular code you would like to see.
    <cairngorm:ServiceLocator
    xmlns:mx="
    http://www.adobe.com/2006/mxml"
    xmlns:cairngorm="
    http://www.adobe.com/2006/cairngorm">
    <mx:RemoteObject
    id="dataService"
    destination="dataService"
    makeObjectsBindable="true"
    source="com.example.apps.reports.service.DataService"
    showBusyCursor="true">
    </mx:RemoteObject>
    </cairngorm:ServiceLocator>
    GetUserCommand.as
    public class GetUserCommand implements ICommand, IResponder{
    public function execute( event : CairngormEvent ): void{
    var delegate:GetUserDelegate = new GetUserDelegate(this);
    delegate.getUsers();
    public function result( data : Object ) : void{
    Alert.show("We got to a result");
    GetUserDelegate.as
    public class GetUserDelegate{
    public function getUsers():void{
    var call:AsyncToken;
    call = service.getUsers();
    Alert.show("Get users was called");
    }

  • [svn:cairngorm3:] 18107: cairngorm3-3.0.16 release for flex3 and flex4

    Revision: 18107
    Revision: 18107
    Author:   [email protected]
    Date:     2010-10-08 14:01:31 -0700 (Fri, 08 Oct 2010)
    Log Message:
    cairngorm3-3.0.16 release for flex3 and flex4
    3.0.16 in flex 4 is
    Reactor Summary:

    Thanks for this update.
    Do you plan to put on this repository only parsley/swiz/... dependencies that Cairngorm libs support or the latest dependencies versions? I was wondering that because I saw you didn't add Parsley 2.3.2

  • [svn:cairngorm3:] 17952: simpler and safer ways to handle flex3 and flex4 sdk and profiles

    Revision: 17952
    Revision: 17952
    Author:   [email protected]
    Date:     2010-09-30 08:02:19 -0700 (Thu, 30 Sep 2010)
    Log Message:
    simpler and safer ways to handle flex3 and flex4 sdk and profiles
    Modified Paths:
        cairngorm3/trunk/build-parent/pom.xml
        cairngorm3/trunk/libraries/lib-parent/pom.xml
        cairngorm3/trunk/pom.xml

  • Flex3 and MS SQL 2k5

    Hey guys;
    Just got the FLEX3 and want to connect to SQL2k5, looks like
    it always fails to connect to my database.
    Any specific steps i need to do using the database Accessor?
    thanks;
    Mike

    Hi Mike,
    Flex Builder connects to SQL Server through a TCP/IP
    connection. This type of connection it might not be enabled for
    your server. Please check if this is the case for you (the default
    port is 1433).
    Regards,
    Miti

  • Potential bug when using Parsley 2.4.1 and Cairngorm's module 0.17 in Flex 4.5.1

    Hi
    I have an issue when using cairngorm's ModuleViewLoader along with ParsleyModuleDescriptor to load a simple module consistig mainly of HBoxes, VBoxes and Datagrids.
    The module consists of one child (let's call it ViewA) and that child consists of several children as its components.
    When I use cairngorm's ModuleViewLoader along with the ParsleyModuleDescriptor and Parlsey to inject the modulemanager in my main app, the module loads, as well as ViewA but some nearly all of ViewA's children are not loaded (in fact they're initialized but creationComplete is not invoked).
    When I use Flex's mx:ModuleLoader all ViewA's chikldren are initialized and creation complete is also invoked.
    I will attach the source as a zip file  later on....
    but for now...this is all I can give http://dpaste.com/713503/
    Thanks
    Andreas

    Did you ever find an answer to this?  I am running into the same issue with needing to upgrade parsley to 2.4.x, but with parts of application heavily relying on cairngorm module, upgrading it from module-0.11 to 0.17 seems to break compile! 

  • Issues with Flex3 and CF8 on Windows Vista

    Sorry for the whine, however I feel it necessary to get a few
    issues I've found with Flex3 on a Vista Laptop working with CF8
    that I've not seen documented elsewhere.
    Environment:
    Sony Laptop with Intel Core 2 Duo processor and 3 GB Ram.
    Running CF 8 Standard Edition, along with mySQL 5.x and
    access to a SQL Server instance on another machine on the same
    local network.
    What I am trying to do:
    A) learn flex, my background is CF with over 8 years of
    experience along with Flash AS2 along the way.
    B) put together a hello world app.
    C) use the flex/cf application wizard to build a simple
    master/detail set of selection/edit screens for one table of a
    database that I used recently on a CF8 project. To see how much
    better the UI really is on Flex and whether I could use it to retro
    fit that old application to have a better UI using flex3.
    Issues.
    My mini-application is set up initially in the folder
    c:/inetpub/wwwroot/mydirectory, but it does not work.
    Reason is that when run, it cannot access the flex2gateway on
    the url that the wizard puts into the app. which is
    http://localhost/mydirectory/flex2gateway...
    Details:
    flex2gateway does not work on a subdirectory URL on the
    default web site.
    If I access
    http://localhost/flex2gateway/
    I get a blank screen (as expected) meaning that the flex2gatweway
    is working.
    If I access
    http://localhost/mysubdirectory/flex2gateway/
    I get a 404.0 error (not found)
    Now, I beleive this is supposed to work, something must be
    wrong with one of the xml file setups. But I cannot find any
    documentation for it.
    Initially the flex2gateway did not work at all. I did the web
    connector thing with CF batch file and that got it working, but
    only on the base directory, not the subdirectory.
    So, to get around this issue, Luckily Vista with IE7 allows
    more than one website.. I create a whole new website that is
    accessed using
    http://192.168.1.73:81/
    I set this website up in the folder c:/localhost/mydirectory.
    The flex project is called mydirectory
    So we come to issue 2.
    Given the above Issue number 1, I have further frustration
    because when the Flex/Cold Fusion Application wizard builds the
    various mxml files it insists on prefixing all of the remote object
    calls with 'mydirectory.'
    e.g "mydirectory.components.cfgenerated.mycfc"
    Now, given that the web root is also the base of the project,
    this will not work.
    What actually works is: "components.cfgenerated.mycfc"
    There seems to be no way I can configure the project when
    building it to get around this issue. The only way |I can fix this
    is to manually edit all the mxml files after the wizard is
    finished. I also have to doctor the project setup for similar
    reasons. It wants all of the urls to be:
    http://192.168.1.73:81/mydirectory/bin/main.html
    instead of
    http://192.168.1.73:81/bin/main.html
    So obviously the wizard is not set up to handle applications
    that are based right at the web root, even though this is the only
    place that the flex2gateway can work. <snafu I guess>
    Issue 3:
    I find that the flex/Cf application wizard is set up to build
    pages based upon a certain narrowly defined way of constructing the
    source database tables. In particular it wants every table to have
    its own unique numeric id for each row, and can't handle a string
    for the primary key and have the primary key editable as well.
    Seems inflexible if you ask me. The main problem is that the
    preconditions on the table structure that the wizard can work with
    are poorly defined and documented. You obviously had to go to the
    same school of database design and the same class as the Adobe
    developers to think in the same way.
    Given that this tool is supposed to be a help to new users of
    Flex and AS3 and it is supposed to be a productivity aid, perhaps I
    should not be surprised to have had to spend over a week getting to
    grips with the wizard and learning its tricks just to get it to
    build a mind numbingly simple mini app of my own that works when
    run. Sorry Adobe, but you get a F minus on your report card for
    this one, particularly on the really bad documentation. Just as bad
    for the coding complexity of the solution to seemingly simple
    application concept.
    Cheers,
    Bryn Parrott

    Hi,
    Which version of RDP client you are using for your client?
    Does more user login at same period of time?
    As you have commented that after sticking the user can’t able to login in RDCB server, here I can suggest you to check the setting of connection broker. Also you can check that you have place the proper location path of UPD while configuring in collection configuration
    wizard. You can take a look at below article foe virtual desktop configuration.
    Deploying Virtual Desktops with Windows Server 2012
    Are you trying to use same UPD for different collection then also it might happens to occur your issue. The fact of UPD is User profile disks are for a single collection only. A user connecting to two different collections will have two separate profiles. If
    you want to synchronize settings, refer to Microsoft User Experience Virtualization. Go through this article for more understanding related to UPD.
    Working with User Profile Disks on Session-Based Desktop Deployments
    Hope it helps!
    Thanks.

  • Channel.Call.Failed NetConnection.Call.Failed: HTTP: Status 500 with amfphp php and mysql

    I have been scripting a simple database connection to check login credentials and am comming accross these errors:
    Channel.Call.Failed
    NetConnection.Call.Failed:
    HTTP: Status 500
    Any PHP code I run that is not connecting to MYSQL runs fine. But if I try to connect to the database thats what I get.
    Here is my mxml:
    <s:RemoteObject id="LogInService"
                                 source="Novus.NovusUser.getLogIn"
                                 destination="AMFPHP"
                                                                fault="faultHandler(event)"
                                 showBusyCursor="true">
                                  <s:method name="getLogIn" result="onResult(event)" fault="faultHandler(event)"/>
    </s:RemoteObject>
    Which calls this actionscript:
    private function btn(event:Event):void
                                                 switch(event.target.id)
                                                           case "LogInSubmit":
                                                                          LogInService.getLogIn(UserName.text, PW.text)
                  break;
                                  private function onResult(result:ResultEvent):void
                                                 Alert.show("Result " + result.token.result);
                                                 if(result.token.result == true)
                                                                currentState = "Main";
                                                 else
                                                           Alert.show(String(result.token.result));
                                  private function faultHandler(fault:FaultEvent):void
                                                 CursorManager.removeBusyCursor();
            var errorMessage:String = "code:\n" + fault.fault.faultCode + "\n\nMessage:\n" + fault.fault.faultString + "\n\nDetail:\n" + fault.fault.faultDetail;
                                                 Alert.show(errorMessage);
    and calls this PHP:
    If I comment out the database connection it returns a false value to me just fine but with it there it throws an error
    <?php
    class GetLogIn
                   private $_db;
                   public function getLogIn($U, $P)
                             //Connect To Database
                             $hostname='127.0.0.1';
                             $username='root';
                             $password='*********';    //not realy ***** blocked it out
                             $dbname='mydatabase';
                             try
                                            mysql_connect($hostname,$username, $password) OR DIE ('Unable to connect to database! Please try again later.');
                                            mysql_select_db($dbname);
                                            $sql = "Select * FROM empusr WHERE UserName = '$U' and Password = '$P'";
                                            mysql_close();
                                            if ($sql)
                                                           return true;
                                            else
                                                           return false;
                             catch
                                            return 'Unable to connect to database! Please try again later.';
    ?>
    I have a crossdomain.xml but I am unsure if I have it placed right.
    I also have a services.conf but am unsure if that also needs to be altered to adjust for MySQL.
    Any help would be appreciated. 

    Found the problum
    The connection string had to be placed in the public _constructor function of the class.
    <?php
    class EmployeeService
              public function __construct()
                        $hostname='127.0.0.1';
                        $username='root';
                        $password='*********';
                        $dbname='myDatabase';
                        mysql_connect($hostname,$username, $password);
                        mysql_select_db($dbname);
              public function logIn($N, $P)
                        $query = "SELECT * FROM EmpUsr WHERE UserName = '$N' AND Password = '$P'";
                        $result = mysql_query($query);
                          if ($result)
                                    return true;
                          else
                                    return false;
    ?>

  • Flex3 and CF8

    I am a Flex newbie, experience ColdFusion user.
    I am using the trial version of Flex Builder 3 to create a
    new project (File/New/Project/FlexBuilder/Flex Project).
    In the New Flex Project window, I enter the project name,
    select "web application" as the application type, and select
    "ColdFusion" as the server technology. The "Use remote object
    access service" is checked, and "LiveCycle Data Services" is
    selected.
    In the next screen - in the server location, I enter
    "Standalone" as the installation type, the webroot is
    "c:\inetpub\wwwroot," and the root url is "
    http://127.0.0.1" (I'm using IIS, so
    I'm not using port 8500). This is the screen where I see error at
    the top - "LiveCycle Data Services is not installed at the
    specified location." But I made sure LiveCycle Data Services was
    installed when I installed ColdFusion8, and "Enable Remote Adobe
    LiveCycle Data Management access" is checked in the ColdFusion
    Administator panel.
    Also, I went back in the New Project dialog and changed the
    server option to "ColdFusion Flash Remoting", and I was able to
    create a new project. However, now I cannot connect to my
    datasources using RDS configuration - I keep getting the error
    "Unable to connect to localhost".
    What is missing? Any help on either of these topics would be
    appreciated. If I can get this to work, it would justify the
    purchase of the full version.

    I assume from your post that you installed ColdFusion 8 onto
    your local machine because you're using 127.0.0.1 as your root URL.
    During the installation you have to select to install RDS (which
    isn't checked by default) AND LiveCycle Data Services; LCDS prompts
    for a serial number, but defaults to a "free" single-CPU license
    after 120 days.
    I had to completely uninstall Coldfusion 8, and reinstall
    (twice) to make sure EVERYTHING was checked/selected for Flex 3 to
    be happy. Try removing the "localhost" default entry for RDS and
    creating your own with the IP address of your PC. Since you're
    running IIS (locally, right?) then RDS should be looking on port
    80, and I think the RDS entry for "localhost defaults to using port
    8500. Once you give it your PC's IP and the password for RDS that
    you create when you installed CF8, you should be able to do a
    successful test to ensure that RDS is even listening. When you
    selected to install to IIS (rather than install CF8's own web
    services) did you also specify "All Websites"?

  • CF/Flex3 and session management

    Does anyone know how to manage user access to CF components
    so that a person must be authenticated before running the
    CFComponent? Otherwise, if I set access to a CF Component to
    "remote" anyone can call it without authentication.
    Thanks!

    Well after a bit of a research and almost a whole day without
    electricity I found out that setremotecredentials is the way to
    pass credentials to CF, and using the CF security framework secure
    the CFC. Then you can authenticate and using cflogin and Roles then
    you're able to use per function security. It's a shame you can
    secure the whole CFC as well. Here you'll find a tutorial.
    http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_18684

  • Flex3 and cocomo?

    I want to know if Cocomo work with Flex 3 or Flex 4?
    Thanks
    Mark

    Hi,
    Cocomo works with Flex 3. Most of the current work we did was
    using Flex 3.
    Cocomo also works fine with Flex 4, I have tried it with one
    of the gumbo builds some days back and it seemed fine. Though we do
    not officially yet provide support for flex 4 builds yet.
    Thanks
    Hironmay Basu

  • Mobile and Cairngorm

    We've been asked recently if Cairngorm3 is relevant and mature for Mobile application.
    Our answer is:
    Yes we did not encounter any roadblocker.
    We started experimenting C3 on Mobile last year for our conference at MAX cf. http://jroller.com/francoisledroff/entry/flex_and_lcds_best_practices
    The only library that we would not use if the mobile app was to be deployed on iOS is the Module library as binary are not allowed to be loaded at runtime on appstore apps, at least that's what I understood.
    In the App Store Review Guidelines among others there are the following rules:
    2.7 Apps that download code in any way or form will be rejected
    2.8 Apps that install or launch other executable code will be rejected

    MikeJamesKenn wrote:
    What are mobile and landline call rates from Spain to UK Germany and Australia
    Hello
    With Skype your location is irrelevant. To see calling rates (from anywhere) please visit here:
    http://www.skype.com/en/rates/#FR
    TIME ZONE - US EASTERN. LOCATION - PHILADELPHIA, PA, USA.
    I recommend that you always run the latest Skype version: Windows & Mac
    If my advice helped to fix your issue please mark it as a solution to help others.
    Please note that I generally don't respond to unsolicited Private Messages. Thank you.

  • What am I doing wrong with Flex 3 and BlazeDS

    I using Blaze, Flex3 and Cairngorm, I have a simple
    application at the moment, in which I dispatch a Cairngorm event,
    it gets picked up the Command is executed and the Delegate can send
    data to the RemoteObject. I can see in the output that Blaze is
    doing what it is supposed to do and returning what it is supposed
    to return, but the data returned never makes it to the IResponder
    result function. What am I doing wrong? Can post code if
    needed.

    +I read on itunes help that I could import CDs to my library without internet connection, and did so to about 10 old ones and now cannot figure out how to get their track/artist names.+
    You get the track/artist names off the back of the CD and type them in yourself.
    You have to have internet for itunes to get them automatically from the gracenotes/CDDB online database.
    Importing one-by-one and editing the info would have been a better scheme. Now you've got a hot mess!
    Unless you know the songs well enough to recognize them when they're played, I don't see how you're going to get it all straight without importing them again.

  • Cairngorm View Helper - Command resuability and tight coupling with view

    I am new to Cairngorm framework. Currently we are converting
    our project to Cairngorm framework. I have some very basic doubts
    regarding the framework. Basically I am a java/J2ee
    programmer and got very good experience in struts framework
    and other J2EE design patterns.
    I have some doubts and needs advice from the community .
    My very first doubt is regarding the ViewLocator pattern used
    in the Cairngorm framework to access
    the view from Command class. At a very high level my
    understanding about command pattern is that command object
    shouldn't know anything about the caller. Command should execute a
    the business logic and update the model.
    But if we use the ViewLocator pattern the command object
    should know about it's caller class and the method name of the
    view/viewhelper class which should be executed after the command
    logic. In this scenario we will not be able to reuse the command
    class and a very tight coupling is established between the command
    and view.
    I have read from flex and cairngorm related blogs about an
    'Observer' and 'ChangerWatcher' patterns which seems to be right
    approach for me rather than using the ViewLocator. But as far as I
    know these are not part of the framework.
    I would like to know what is the recommended approach from
    the cairngorm framework team for executing View related logic after
    firing the Cairngorm event.
    If we use the ViewLocator pattern, there is no reusability as
    far as the command is concerned and also a very tight coupling is
    happening with the command and view.
    Is this the right approach..?
    Please advice..

    Hi, the view Locator has very issues that we have to have in mind, y most of the  problems are similar when we are using the Drag Manager , when we are using modules and load this view dynamically.
    The solution is simple and you told it. Binding by Watchers in the model Locator and checking the model locator variables when we load a module.
    In the view that we want to change we can add a Change Watcher linking a model locator variable to a function in the view, we change the model in de command and automatically change the value in the view.
    There are 2 ways to do the same concept, but is good only when the call to a cairngorm only affects the view that its calling it and known more has to know, so in theory you don’t need to change the model to impact the view.
    First is adding a Iresponder in to the event by Get Set so in the view, when you create a event for cairngorm and have to pass through the event an IResponder  (mx.rpc.IResponder). When you are in the command in the result or fault you can do event.responder.result = event or event.responder.fault = event and this well go directly into the view result o fault. So you don’t have to pass through the model. (Responder is your get set in the Event of private var _responder:IResponder)
    The other way is the same but using UM cairngorm that has CallBacks. And it’s pretty much the same but the event and all the cairngorm has callbacks and notifyCaller.
    Well I hope I said something useful.
    I did a UM cairngorm diagram in English http://www.developyourdream.net/tutoriales/tutoriales_flex_avanzados/cairngorm_universal_m ind/Cairngorm.swf
    Sorry me English and if somebody talks Spanish you can go check my blog http://www.developyourdream.net/ 

  • AMFPHP and remoting components

    I am attempting to get AMFPHP going and have just installed
    the latest remoting components.I get these errors when running any
    samples I have found.
    **Error** NetServices.as: Line 24: Error opening include file
    RemotingComponentVersion.as: File not found.
    #include "RemotingComponentVersion.as"
    **Error** NetServices.as: Line 24: Error opening include file
    RemotingComponentVersion.as: File not found.
    #include "RemotingComponentVersion.as"
    Anybody experience this and or can offer a solution?

    did you drag and drop the remoting component classes from
    "Window ->
    Common Libraries -> Remoting" into your library?
    perry

Maybe you are looking for

  • Taxes and duties on components for cost plan

    Hi experts I am working for below scenario: The components those are planned must be added with applicable taxes for cost plan. In case of imported goods, the applicable import duties need to be added to cost plan. Similarly in case of external servi

  • Pixelated images in IDCS

    I have imported tiff images (from CS3, gray scale tiffs @ 300dpi) into IDCS document. It's a repeated file that is used as varying scales. The file is also colored within IDCS. The problem is that some of these images are becoming piexated in the out

  • Required Field Left Blank

    I'm sure that I'm missing something simple; however, the form on this page < http://www.howardcore.com/bad_link_form.html> worked a couple weeks ago when I put it online, and now upon form submission tells the user that they have left a required fiel

  • Error in GR Update control of movement type is incorrcet (entry 101 _ _ _ B

    PO is created using Non-stock matreial and while doing good receipt of this PO user is getting error "Update control of movement type is incorrcet (entry 101 _ _ _ B). Message No. M7226. Plesae help.....

  • Script Font Styles

    I am currently using the CFR Builder 8. When I am design mode I can apply a script font style and see the font style no problem but, when I pull the report from the web the font style reverts back to a non-script type. Any and all help will be greatl