Problem with the exercise of the Http Service

Hello

I am trying to load an xml file and displays the result in a data grid. In fact, I followed the tutorial provided by the exercise of the http service. The foollowing code I used.

<? XML version = "1.0" encoding = "utf-8"? >
" < = xmlns:mx mx:Application ' http://www.Adobe.com/2006/MXML "
layout = "absolute".
Initialize = "employeeService.Send ()" >
< mx:Script >
<! [CDATA]
Import mx.collections.ArrayCollection;
Import mx.rpc.events.ResultEvent;

[Bindable]
private var employeeData:ArrayCollection;

private void resultHandler(event:ResultEvent):void {}
employeeData = event.result.employees.employee;
}
[]] >
< / mx:Script >

< mx:HTTPService id = "employeeService".
result = "resultHandler (Event)" "
URL="~/data/employees.xml"/ >

< mx:DataGrid dataProvider = "{employeeData}.
Width = "100%" height="100%"/ >
< / mx:Application >

The following xml code is used with the name like employes.xml:

<? XML version = "1.0" encoding = "utf-8"? >
< employees >
< employee >
< firstname > Sreelash < / name >
< name > S < / lastname >
Sree < id > < /ID >
< title > Junior Software Engineer < /title >
< Email > [email protected] < / email >
called < managerid > < / managerid >
< And > Development Department < / Department >
the < location > India < / location >
< Phone > 09995107016 < / phone >
< and > 9995107016 < / WC >
< desklocation > 45 < / desklocation >
< City > Thiruvananthapuram < / City >
Kerala < of State > < / State >
< > 0091 countrycode < / countrycode >
< code postal > 695024 < / code >
< / employee >
< / employees >

Thank you and best regards,

Sreelash.

Hello

The ArrayCollection collection is supposed to work with more than 1 result.  Your XML file has only 1 record.  If you add an another (or several) records and then fill your Datagrid.  However, you can make it work with 1 card by replacing the variable employeeData in the dataProvider with this:

<>
dataProvider = "{employeeService.lastResult.employees.employee}".
Width = "100%" height = "100%" / >

Here you access the HTTPService control lastResult property. If you decide to add more records in your XML file, and then it displays all the records in your Datagrid control.

Hope that helps?

Tags: Flex

Similar Questions

  • Update Windows problem with the Bits Service and error 0 x 80070057

    The service status: problem with the Bits Service

    Error 0 x 80070057

    Original title: Windows Update problems

    Hi Dexter,

    Can I know the KB # the update fails?

    What is the question pertaining to a specific or all update updates?

    What antivirus software you use on your computer?

    To resolve this problem, see the following article:

    Difficulty errors Windows Update corruption as 0 x 80070002 and 0 x 80070057

    Hope the helps of information. Get back to us with more information to help.

  • Service Windows wireless suddenly stopped working because of problem with the KeyIso service

    Description of the problem: Windows Wireless Services suddenly stopped working on my computer. What I have discovered so far that the problem is that the WLAN AutoConfig service does not work because of the failure of the function "KeyIso". The error message for the mentions "Error 126" KeyIso (the specified module could not be found). Any help to fix this would be appreciated. TDW

    Hello

    What is the antivirus installed on the computer program?

    KeyIso Description:

    The service provides insulation for private keys key processes and operations of such associated encryption required by the common criteria. The service stores and uses long term keys in a secure process in line with the requirements of the common criteria. It should normally be disabled, as otherwise, these cryptographic operations may fail.

    Looks like there could be a corruption with the wireless connection that you have added. You can perform the steps.

    Method 1:

    Try to manually start the wireless service, i.e. the WLAN AutoConfig service. To do this, connect to the computer as an administrator.

    a. Click Start, type services.msc and press enter.
    b. Locate the Autoconfiguration WLAN service, double-click to open its Properties window.
    c as. under the general tab, change the startup type to Automatic and click on the Start button.
    d. click on apply, then ok.

    Method 2:

    To resolve this problem, try using the tool (SFC.exe) System File Checker. To do this, follow these steps:

    How to use the System File Checker tool to fix the system files missing or corrupted on Windows Vista or Windows 7
    http://support.Microsoft.com/kb/929833

    Method 3:

    You can uninstall and reinstall the network card and check.

    a. click Start, type Device Manager in the Start search box and press enter.
    b. locate the network adapters and expand the same.
    c. Select the Wireless connection, right click and choose Uninstall.
    d. restart the computer, if prompted.

    Drivers should settle automatically after the computer restarts.

    Now you can install the latest network card drivers and see if that fixes the problem.

    http://Windows.Microsoft.com/en-us/Windows7/update-a-driver-for-hardware-that-isn ' t-work correctly

    Windows wireless and wired network connection problems
    http://Windows.Microsoft.com/en-us/Windows/help/wired-and-wireless-network-connection-problems-in-Windows

    Hope this information helps. Response with status so that we can help you.

  • Problem with the search service on a Windows Server 2012 R2

    Hi all

    I'm having problems setting up my newly installed Server vCenter server.

    Everything seems to be installed properly, at least I got no error message and I am able to connect to the Web Client vSphere.

    However, I can't create a data center as the inventory does not display any server...

    Weird, isn't it?

    When I try to access to the https://localhost:7444 / lookupservice page, a message tells me that the service is not available.

    Is there something else to do here?

    Something else weird to me, a beginner in VMWare environments, is that although I'm loging as administrator, it seems that I have not at all privilege. For example, for roles see, access to licenses and so on.

    How I setting a user administrator 'real '?

    Do you think that my problem might be this question of privilege? And that I do not see any server in the inventory because my administrator user does not have the appropriate rights to view it?



    Thanks in advance for any help you can provide.


    Kind regards


    Jeremy

    OK Guyz... My bad.

    Actually, I connect with the user local administrator instead of the user [email protected].

    Now everything seems fine.

    Sorry for the inconvenience! ;-)

    Jeremy

  • Problems with the Web Service using XML in Flex

    Hello

    I use a ColdFusion CFC, which is configured to generate an XML string. It runs on ColdFusion MX 6.1 and is configured as a remote web service. I tested the call and it returns the string XML fine when it is called from another method of Flex unfounded. My problem is this simple Flex application to call the same function via a service web, I wrote below. I cannot get to the exit results, keeps showing as NULL. I can't use the HTTP of Flex appeal for remote access because I'm not under MX7. Does anyone know what is wrong with my code? BTW, I would do the work of cross - domain.xml file to call the cfc, let me know if you want to test and I can add your domain name. Thank you!

    <? XML version = "1.0" encoding = "utf-8"? >
    "" < mx:Application xmlns:mx = ' http://www.adobe.com/2006/mxml ' layout = "absolute" >

    <! - set Web Service to get the XML data of course catalog - >
    < mx:WebService
    ID = "cd".
    "WSDL =" http://training.wonderware.com/components/courses.cfc?wsdl "
    Load = "CD.getCourseCatalogXML.Send ()" "
    showBusyCursor = "true" fault = "Alert.show (event.fault.message), 'Error' ' result =" cdResult (event) ">"
    < mx:operation name = "getCourseCatalogXML" resultFormat = "e4x" >
    < mx:request >
    < IDCalendrier > 3 < / IDCalendrier >
    < / mx:request >
    < / mx:operation >
    < / mx:WebService >

    < mx:Script >
    <! [CDATA]
    Import mx.controls.Alert;
    Import mx.rpc.events.ResultEvent;
    Import mx.rpc.events.FaultEvent;

    [Bindable]
    public var outputString:String

    public void cdResult(event:ResultEvent):void
    {
    outputString = event.result as String
    }
    []] >
    < / mx:Script >

    < mx:Canvas horizontalScrollPolicy = "off" verticalScrollPolicy = "off" >
    < mx:Text width = '100% ' paddingLeft = "4" paddingRight = paddingTop "4" = "4" >
    < mx:text > OUTPUT: {outputString} < / mx:text >
    < / mx:Text >
    < / mx:Canvas >

    < / mx:Application >

    Thank you very much! I do not have the notion that the HTTPService is indded just an HTTP call. So yes that it a much simpler way to call just ColdFusion to return the XML string to the application. No reason to use Flash Remoting or CFCS etc... and certainly not a web server. This made the turn that I called a HTTPService now what charges by coldfusion page that returns XML and bam, works well with e4x result etc... Thanks tracy!

  • Today, I have a problem with the HTTP request

    Well, this time, I try to get an image .png from a URL. To get this I do the following:

    try{   if (CoverageInfo.isOutOfCoverage()){      setError("No hay covertura suficiente de la red");        errorFlag = true; } else{     c = (HttpConnection)Connector.open(url);      is = c.openDataInputStream();     for(int j=0;j
    

    My problem is the second 'try' returns: "java.lang.illegalArgumentException". I don't really know much on HTTP conections, so I don't know that I have a lot of wrong code

    in other words, I'm moving to the java language this short code on the C++ language:

    WebRequest request = System.Net.WebRequest.Create(url);HttpWebResponse response = (HttpWebResponse)request.GetResponse();Stream datos = response.GetResponseStream();Imagen = new Bitmap(datos);pb1.Image = Imagen;datos.Close();response.Close();
    

    can someone help me?

    Thank you RexDoug and peter_strange,

    in the book "java J2ME a tope"-unfortunately or fortunately (for me), it is in Spanish - explain everything about HTTP request and how to interpret correctly the answer. Finally with the following code, I solved my problem:

    try{
        //ask if i have coverage
        if (CoverageInfo.isOutOfCoverage()){
            setError("No hay covertura suficiente de la red");
            errorFlag = true;
        }
        else{
            //create connection
            c = (HttpConnection)Connector.open(url);
            c.setRequestMethod(HttpConnection.GET);
            is = c.openInputStream();
    
            //process response
            if(c.getResponseCode()==HttpConnection.HTTP_OK){
                size = (int)c.getLength();
                if(size != -1){
                    data = new byte[size];
                    is.read(data, 0, data.length);
                    imagen = Bitmap.createBitmapFromBytes(data, 0, -1, 1);
                }
                else{
                    ByteArrayOutputStream byteArray = new ByteArrayOutputStream();
                    int stream;
                    while((stream=is.read())!=-1){
                        byteArray.write(stream);
                    }
                    data = new byte[byteArray.size()];
                    data = byteArray.toByteArray();
                    byteArray.close();
                    imagen = Bitmap.createBitmapFromBytes(data, 0, -1, 1);
                }
            }
            //close connections
            c.close();
            is.close();
        }
    }
    

    This code is similar to the example of rexdoug.

  • BlackBerry Smartphones Blackberry curve 9380 problem with the sos service

    Dear

    BBM

    I am from pakistan

    in 2013, I bought blackberry curve 9380 that it worked well without any problems.

    only 8 months before it shows the installation of the sos service fail.

    I updated a new os in it even it's show same problem so kindly give me the precise of the IDF solution so that I should use.

    model. 9380 curve

    PIN code. [removed personal information]

    BT MAC - 80 60 07 7 BB 20

    Made in Malasia

    It is a forum sponsored by BlackBerry user. I am a user like you.

    I do not understand "SOS service installation failed. What is installation of service in this context with SOS?

    I'm guessing that you mean that you are the only emergency service. I would have again assumed SIM card problem before the problem of the OS.

    Have you tried another SIM card in your BlackBerry and tried your SIM in another phone?

  • Problem with the internet service of blackBerry Smartphones

    Hi, I had my BB curve less than a month, so I'm still learning.  I can access internet for most sites, but the one that I want - I can not go beyond the main connection.  I am an AVON representative and want to be able to access my AVON site but when I connect, it just reloads the same page - doesn't give me any error messages or anything.  AT first, he said I had to activate Java script - I went to options and enabled the Jave script - but still no luck.  Does anyone have any suggestions.  I have no problem with other sites, but I have not tried all the others I actually connect.

    Thank you

    Sorry I took so long.

    I don't have to connect that I was checking to see if he had all the elements that would keep the BB to access the site.

    I can't speak to the internals.

    I would recommend a third party FREE application. It is called opera mini, another type of browser. It shows the page of the entire site and you can zoom in on what you want on the page. I had the chance to connect to sites on this

    App. I guess that a second reason for you would be especially in the search for the pages of products etc.

    Sorry I couldn't be more helpful. If you could please take a moment to solve this thread using the green check mark in the post that is closest to you to answer your question, I would appreciate it.

    Here is the link for Opera mini, go on your BB and download, be sure to allow all connections. Try it and see if it helps. If you need help, just open a thread and we will help you with it.

    Thank you

    http://www.operamini.com/download/

  • Problem with the listening Service: Long delay beginning listener, intermittent connections

    I have problems to connect to my Oracle database.  I don't know what was the cause, but now when I connect to a database that has been working well for the past two years, I usually get an ORA-12541 error.

    I run lsnrctl status on the server and get a prinout like this:

    Copyright (c) 1991, 2010, Oracle.  All rights reserved.

    Connection to (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST=dqaswn02) (PORT = 1521)))
    AMT-12541: TNS:no listener
    AMT-12560: TNS:protocol adapter error
    AMT-00511: no listener
    Windows 64-bit error: 61: unknown error
    Connection to (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC1521)))
    AMT-12541: TNS:no listener
    AMT-12560: TNS:protocol adapter error
    AMT-00511: no listener
    Windows 64-bit error: 2: no such file or directory

    I also tried to manually stop the service through services.msc, then by restarting via lsnrctl start, but when I do this I get a very long delay (10 + minutes) before he comes back with something like:

    TNS-01153: failed to process the string: 0i

    I'm quite lost as to what is wrong.  I've been messing around with listener.ora, but I don't see anything difficult in there.  Here's a copy:

    listener.ora # Network Configuration file: E:\app\myc0714\product\11.2.0\dbhome_1\NETWORK\ADMIN\listener.ora
    # Generated by Oracle configuration tools.

    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = CLRExtProc)
    (ORACLE_HOME = E:\app\myc0714\product\11.2.0\dbhome_1)
    (= Extproc PROGRAM)
    (ENVS = "EXTPROC_DLLS=ONLY:E:\app\myc0714\product\11.2.0\dbhome_1\BIN\OraClr11.dll")
    )
    )

    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = dqaswn02) (PORT = 1521))
    )
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = CIP)(KEY = EXTPROC1521))
    )
    )

    # ADR_BASE_LISTENER = E:\app\myc0714
    LOG_FILE_LISTENER = LISTEN PORT
    TRACE_LEVEL_LISTENER = SUPPORT
    TRACE_FILE_LISTENER = LISTEN PORT

    A few times during that time, I was able to connect to the server, via sqlplus, however, it took 10 minutes before the connection is online.  Once I'm connected, I can ask my paintings as expected, but I need an application to connect.

    If anyone has any ideas on what could be the problem, please let me know.

    In fact, there was another thing, I changed when I finally got it works, although I don't know if it was related or not.  In my folder with my track logs, I had a huge (> 4 GB) listener.log file.  I deleted this file right before that I ran the command netsh command to reset and then restarted.  This file was also a bit special, because it had not been updated since around the time that I first encountered this problem.  It seems to be updated on a minute by minute basis, now that I've removed the old.  Is there a problem with this file becomes too big?  My drive was not out of space, but it is very curious that this stopped file update on the same day as when I started having the problem and now works properly again.  I wish I had noted the exact time until I deleted it.

    Link:

    Problem of Listener.log & #8211; large file | Obtained & #039; s Blog

  • Problem with the web service call

    I use ajax with json to call webservice but its not working with the localhost url in the emulator of the ripple. If I use an ip address or external url does not call the webservice.

    I also tried with BlackBerry, webservice does not.

    can someone guide me how to call the Web service?

    Thank you

    Sundaram

    Your file config.xml needs the ip address or the url in the "whitelist".  Use the access for that tag.  for example:

    
    

    The piece above is not secure because it whitelists ALL------* areas.  You can put your url in the uri.

  • Problems with the Hello service

    Can someone tell me for Win7 32 bit... As it is not working properly... The Hello service do not work properly... PLZ help me in this situation

    Separated from the:

    http://answers.Microsoft.com/en-us/Windows/Forum/Windows_7-windows_programs/Bonjour-services-failed-to-start-verify-sufficient/98899444-8aa0-47A6-BA0F-fcd7375a6c58?page=2#LastReply

    Hi again,

    «Hello: frequently asked questions (FAQ)»

    http://support.Apple.com/kb/ht2250

    "Q: Why am I not Hello on my Windows system? ."

    If you install Windows Hello manually, the more likely reason is that it has been installed by an application that relies on the features of Hello. For example:

    • iTunes uses Hello looking for music libraries shared, to find AirPort Express devices to listen to music to and find the Apple TV. »
  • problems with the connectivity services and ePrint 310a

    I just got a HP 310a as a replacement for what said HP was a 210 a defective. The 210 a would not stay connected to my network and support HP gives up and sent me a gift card to buy a replacement.

    I've set up the replacement. He also had the problem of connectivity but other features wireless everything has worked well. I could print by e-mail to a dedicated e-mail address and printing via my ipod using HP iprint app.

    While he was trying to use the previous suggestions of support to solve the problem of connectivity, the printer now has lost its ability to connect to web services and I can't activate the features of eprint. "" When I try to connect to web services, I get an error message indicating that "web server problem" "problem connecting to the web server.

    I set up the printer with a manual address and that is where the problem started.

    Please, any suggestions how to get this resolved.

    Here's what I recommend:

    1 set a static IP address, but make sure that it is outside the range of your router's DHCP.  If your router uses the range (.2 a.254, reduce the a.2 a.200 beach or something and then assign the printer apart from this, comme.220.)

    2 the gateway address goes into the field of the bridge and the first DNS entry.  Do not fill in the second.  The IP Address of the gateway usually ends par.1

  • Problems with the MSXML6 Service Pack

    You try to download an accounting program and receipt following in the accounting program error... Program could not download SQL Server 2005 Express, we should try to manually download from Microsoft. Tried and received the message that we didn't need to do that, because we have a more recent version. Contacted the software and has been said to see if whatever it is listed as MSXML6, if there is uninstall it and restart. Tried and received MSXML6 Service Pack 2 (KB973686) error fatal error during installation. Do you have any suggestions?

    Hi cowboynd,

    Yes. Try this automated correction.

    http://support.Microsoft.com/kb/968749

    Hope it will be useful.

  • There was a problem with the Windows Live Hotmail service (a network connectivity problem temporary has nothing to do with your computer).

    There was a problem with the Hotmail service (a network connectivity problem temporary has nothing to do with your computer). Please try again

    . I really need to fix this! Help!
    original title: no answer not before!

    track every step!

    no change!
    I am getting really worried about it!

    Please ask in the forum Hotmail. We do not use it. We cannot answer your question.

    Windows Live Solution Center Hotmail Forum
    http://windowslivehelp.com/forums.aspx?ProductID=1

  • Cannot install Vista service pack 2 is 800f0a09 error code with the message that there are problems with the driver for dell latitude

    Original title: why I get error code 800f0a09 to upgrade to windows vista service pack 2

    I have a laptop del that is running on Windows Vista Edition Home Premium. I tried to download itunes but it requires service pack 2. Whenever I try to update to service pack 2, I get the message following error code 800F0A09. He also mentioned problems with the driver for dell latitude. What can I do to fix this please.

    Thank you

    Hello

    Please join Microsoft Community where you can find the necessary information on Microsoft products!

    You can not install Vista Service pack 2 and get the error with code 800f0a09 and the message that there are problems with the driver for dell latitude.

    The problem may occur if some of the components of the update are corrupt.

    What is the full error message that you receive?

    I suggest you follow the steps mentioned below to check if the problem is with the update components:

    Method 1: Reset the update components

    See the site:

    How to reset the Windows Update components?

    http://support.Microsoft.com/kb/971058

    Warning: This section, method, or task contains steps that tell you how to modify the registry. However, serious problems can occur if you modify the registry incorrectly. Therefore, make sure that you proceed with caution. For added protection, back up the registry before you edit it. Then you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click on the number below to view the article in the Microsoft Knowledge Base:

    http://Windows.Microsoft.com/en-us/Windows-Vista/back-up-the-registry

    Method 2: Run the system update readiness tool

     

    See the site:

    System update scan tool corrects errors of Windows Update in Windows 8, Windows 7, Windows Vista, Windows Server 2008 R2 and Windows Server 2008

    http://support.Microsoft.com/kb/947821

    Method 3: Turn off the antivirus software

     

    See the site:

    Disable the anti-virus software

    http://Windows.Microsoft.com/en-in/Windows-Vista/disable-antivirus-software

    Important note: Antivirus software can help protect your computer against viruses and other security threats. In most cases, you should not disable your antivirus software. If you need to disable temporarily to install other software, you must reactivate as soon as you are finished. If you are connected to the Internet or a network, while your antivirus software is disabled, your computer is vulnerable to attacks.

    I hope this helps. If the problem persists, let know us and we would be happy to help you.

Maybe you are looking for

  • FFT of the signal

    Hello Im trying to understand our noise of a laser. My setup is Laser - detector-Oscilloscope. I read the signal using a GPIB and Labview program. I think that I must take the FFT of the signal produced but it gives me nothing. I plugged the output s

  • DVD Player detects only not MSI Motherboard 865PE-Neo3

    Hello I just finished one of my two friends to fix computers. One is the ASUS MB (computer) and the other Mo MSI (so there is no confusion). Note: both computers are built to order. The ASUS I completely fixed and works 100%. The MSI computer isn't "

  • problems to renew the ip address on the windows xp desktop

    I have a dell Windows xp pc.  Internet has always worked well. I have att dsl, my modem is motorola router and cisco/linksys e1000 (crappy system). before I had the 2wire, which worked FINE. in any case, it was an original idea upgrade att I followed

  • Unbootable

    Hello I was with my HP Pavilion G4 with windows 7 more early tonight when the screen suddenly overshadowed. No pop, no sizzle, just deleted. I close it using the power button and tried to restart. All I get is a very quick flash of the LED on the cap

  • (Redirected) Dell doesn't care

    Posted here:http://en.community.Dell.com/support-forums/customercare/f/4674/t/19591542.aspx