2 Replies Latest reply on Dec 25, 2009 10:18 PM by kkc_mca

    Data not pulling

    Genos_Free

      I have an index file that is I need to pull data in another state.

      The data is an xml file and I am unsuccessfully trying to pull that data into a data grid in another state.

      I would also like to link that data grid to link into another state.

      Please assist.

       

      Thanks and Merry Christmas.

       

      -------------------------------------------------

      <?xml version="1.0" encoding="utf-8"?>
      <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
                     xmlns:s="library://ns.adobe.com/flex/spark"
                     xmlns:mx="library://ns.adobe.com/flex/halo" minWidth="1024" minHeight="768"
                     xmlns:comps="components.*" height="652" backgroundColor="0xcccccc"
                     viewSourceURL="srcview/index.html">
          <fx:Script>
              <![CDATA[
                  import mx.collections.ArrayCollection;
                  import mx.rpc.events.ResultEvent;
                  import mx.events.FlexEvent;
                 
                  [Bindable]
                  private var FAQS:ArrayCollection;

       

                  protected function FAQServices_resultHandler(event:ResultEvent):void
                  {
                      FAQS = event.result.main.SYSTEMLEVEL;
                  }

       

              ]]>
          </fx:Script>
          <s:states>
              <s:State name="State1"/>
              <s:State name="GPS_AT_SYSTEM_LEVEL"/>
              <s:State name="GPS_RECEIVER_OPERATIONS"/>
              <s:State name="GPS_RECEIVER_SUSTAINMENT"/>
              <s:State name="GPS_RECEIVER_INSTALLATIONS"/>
          </s:states>
          <fx:Declarations>
              <s:HTTPService id="FAQServices" url="data/FAQ.xml"
                             result="FAQServices_resultHandler(event)"/>
             
          </fx:Declarations>
         
          <s:Panel
                   width="985" height="624"
                   x="5" y="5">
              <s:VGroup left="10" right="10" top="10" bottom="10">
                 
                  <mx:TabNavigator id="tn"  width="938" height="564">
                      <!-- Define each panel using a VBox container. -->
                      <mx:VBox label="Home">
                          <comps:home id="home" height="460" width="914"/>
                      </mx:VBox>
                     
                      <mx:VBox label="Breaking News">
                          <mx:Accordion id="BNews" resizeToContent="true" width="100%" height="100%">
                              <s:NavigatorContent label="December 2009" width="100%" height="100%">
                                  <comps:BN_Dec2009 id="dec2009" />
                              </s:NavigatorContent>
                              <s:NavigatorContent label="May 2009" width="100%" height="100%">
                                  <comps:BN_May2009 id="may2009"/>
                              </s:NavigatorContent>
                              <s:NavigatorContent label="April 2009" width="100%" height="100%">
                                  <comps:BN_April2009 id="april2009"/>
                              </s:NavigatorContent>
                              <s:NavigatorContent label="What You Get:" width="100%" height="100%">
                                  <comps:BN_WhatYouGet id="WhatYouGet" />
                              </s:NavigatorContent>
                              <s:NavigatorContent label="Added Notes:" width="100%" height="100%">
                                  <comps:BN_AddedNotes id="AddedNotes" />
                              </s:NavigatorContent>
                              <s:NavigatorContent label="January 2008:" width="100%" height="100%">
                                  <comps:BN_January2008 id="January2008" />
                              </s:NavigatorContent>
                              <s:NavigatorContent label="June 2007:" width="100%" height="100%">
                                  <comps:BN_June2007 id="June2007" />
                              </s:NavigatorContent>
                              <s:NavigatorContent label=" Pre June 2007:" width="100%" height="100%">
                                  <comps:BN_BeyondMay2007 id="PreJune2007" />
                              </s:NavigatorContent>
                          </mx:Accordion>
                      </mx:VBox>
                     
                      <mx:VBox label="Frequently Asked Questions">
                          <mx:Label text="GPS Frequently Asked Questions (FAQ's)" fontWeight="bold" color="#F70707" textDecoration="underline" includeIn="State1"/>
                          <s:RichText  text="This set of FAQ and Answers is focused on the DAGR and PLGR handheld military GPS receivers.  We base this information on the most commonly asked questions from field users.  In all cases, more detailed answers are available by searching the index in either the DAGR or PLGR Operations Manuals." width="935" height="29" color="#F70707" includeIn="State1"/>
                          <mx:LinkButton label="GPS AT SYSTEM LEVEL" includeIn="State1" color="#F70707" click="currentState='GPS_AT_SYSTEM_LEVEL'"/>
                          <s:Label includeIn="GPS_AT_SYSTEM_LEVEL" text="GPS AT SYSTEM LEVEL" fontWeight="bold" color="#F90404" textDecoration="underline" fontSize="15"/>
                          <s:Label text="GPS RECEIVER OPERATIONS" fontWeight="bold" color="#F90404" textDecoration="underline" fontSize="15" includeIn="GPS_RECEIVER_OPERATIONS"/>
                          <s:Label text="GPS RECEIVER SUSTAINMENT" fontWeight="bold" color="#F90404" textDecoration="underline" fontSize="15" includeIn="GPS_RECEIVER_SUSTAINMENT"/>
                          <s:Label text="GPS RECEIVER INSTALLATIONS" fontWeight="bold" color="#F90404" textDecoration="underline" fontSize="15" includeIn="GPS_RECEIVER_INSTALLATIONS"/>
                          <mx:LinkButton includeIn="State1" label="GPS RECEIVER OPERATIONS" enabled="true" color="#F70707" click="currentState='GPS_RECEIVER_OPERATIONS'"/>
                          <mx:LinkButton includeIn="State1" label="GPS RECEIVER SUSTAINMENT" color="#F70707" enabled="true" click="currentState='GPS_RECEIVER_SUSTAINMENT'"/>
                          <mx:LinkButton includeIn="State1" label="GPS RECEIVER INSTALLATIONS" enabled="true" color="#F70707" click="currentState='GPS_RECEIVER_INSTALLATIONS'"/>
                          <mx:DataGrid includeIn="GPS_AT_SYSTEM_LEVEL" dataProvider="{FAQServices}" enabled="true" editable="false" width="380" creationComplete="FAQServices.send()">
                              <mx:columns>
                                  <mx:DataGridColumn headerText="System Level Questions" dataField="Question"/>
                              </mx:columns>
                          </mx:DataGrid>
                      </mx:VBox>
                  </mx:TabNavigator>
                 
              </s:VGroup>
          </s:Panel>
         
         
         
      </s:Application>