PSP Flash 7 | XML data storage

Hi all
I amtrying to get some XML working on the PSP. I am
developing for Flash 7. The XML procedure that I am using is
working fine on my PC. Anybody got any opinions or remedies for
this problem.
regards
john
http://www.javono.com

Flash 6, I am developing in Flash 6 not 7. NF3 6

Similar Messages

  • Flash xml data loading and unloading specs

    hi i am trying to get specification information that i cannot
    find anywhere else.
    i am working a large flash project
    and i would like to load xml data into the same swf
    object/movieclip repeatedly.
    as i do not want the previously loaded items to unload i need
    to know if doing this will unload the items from the swf or just
    keep them in the library so they can be reposted without reloading.
    i cannot find any supporting documenation either way that
    tells me that if i load new content into a clip (i am aware
    levels overwrite) if it will or will not unload this content.
    thanks in advance.
    mk

    this is awful for me -- i cant even get the clip to duplicate
    -- and i thought this would be the simplest solution to keeping
    everything cached for one page before and one page after current in
    the project.
    i have used a simpler clip to test the code and see if i am
    insane.
    duplicateMovieClip(_root.circle, "prv", 5);
    prv._x = 300;
    prv._y = 300;
    prv._visible = true;
    prv.startDrag();
    this ALWAYS works when i use the _root.circle file of a green
    simple circle
    BUT
    when i change it to my main movie clip (which is loaded AND
    On screen -- it just doesnt duplicate at all!) -- i've even
    triggered it to go play frame 2 JUST IN CASE
    I've even set visibility to true JUST IN CASE
    ie all i do is change _root.circle to _root.cur
    and .... nada.
    AND _root.cur IS DEFINITELY on the screen and all xml
    components have been loaded into it. (it is a slide with a dynamic
    picture and dynamic type and it 100% works)
    has anyone had this insanity happen before?
    is this an error where flash cannot attach movie or duplicate
    a clip that has dynamic contents???

  • XML data storage - How to handle symbol ' inside xml data from java code

    Hi
    I'm trying to store XML data in Oracle XML DB 10gR2 both through SQL and JAVA .
    I have a simple test table called xmltable with a primary key and a XMLType column
    My sql is:
    insert into xmltable values ('020', sys.XMLType.CreateXML(
    '<?xml version="1.0"?>
    <Mpeg7 xmlns="urn:mpeg:mpeg7:schema:2001">
    <DescriptionMetadata id="2005">
    <LastUpdate>2006-10-19T12:48:22.null+01:00</LastUpdate>
    <Creator/>
    <CreationTime>2006-10-19T12:48:22.null+01:00</CreationTime>
    <Instrument>
    <Tool>
    <Name>LAS MPEG-7 Services v1.0</Name>
    </Tool>
    </Instrument>
    </DescriptionMetadata>
    <Description xsi:type="urn:ContentEntityType" xmlns:urn="urn:mpeg:mpeg7:schema:2001" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <MultimediaContent xsi:type="urn:ImageType">
    <Image id="2005">
    <MediaInformation>
    <MediaProfile>
    <MediaFormat>
    <Content/>
    <Medium href="urn:mpeg:MPEG7MediumCS:2.1.1"/>
    <FileFormat href="urn:mpeg:IPTCMimeTypeCS:image/jpeg"/>
    <FileSize>2782043</FileSize>
    <VisualCoding>
    <Format colorDomain="color" href="urn:mpeg:MPEG7VisualCodingFormatCS:1"/>
    <Frame height="11604" width="8676"/>
    </VisualCoding>
    </MediaFormat>
    </MediaProfile>
    </MediaInformation>
    <MediaLocator>
    <MediaUri>oracle:bosch.informatik.rwth-aachen.de:1521/SMILEY/AMSDB.MEDIA_IMAGE/IMAGE[IMG_ID=2005]</MediaUri>
    </MediaLocator>
    <TextAnnotation>
    <FreeTextAnnotation>B?miy?n and Shikari areas</FreeTextAnnotation>
    </TextAnnotation>
    <Semantic>
    <SemanticBaseRef href="oracle:bosch.informatik.rwth-aachen.de:1521/SMILEY/AMSDB.OBJECT_XML/MPEG7_SB#/mpeg7:Mpeg7/mpeg7:DescriptionMetadata[@id='65']"/>
    <SemanticBaseRef href="oracle:bosch.informatik.rwth-aachen.de:1521/SMILEY/AMSDB.OBJECT_XML/MPEG7_SB#/mpeg7:Mpeg7/mpeg7:DescriptionMetadata[@id='148']"/>
    </Semantic>
    </Image>
    </MultimediaContent>
    </Description>
    </Mpeg7>
    Unfortunately I'm facing problem with the symbol ' at the tags:
    <SemanticBaseRef href="oracle:bosch.informatik.rwth-aachen.de:1521/SMILEY/AMSDB.OBJECT_XML/MPEG7_SB#/mpeg7:Mpeg7/mpeg7:DescriptionMetadata[@id='65']"/>
    <SemanticBaseRef href="oracle:bosch.informatik.rwth-aachen.de:1521/SMILEY/AMSDB.OBJECT_XML/MPEG7_SB#/mpeg7:Mpeg7/mpeg7:DescriptionMetadata[@id='148']"/>
    If I tried with double ' (not '' ) it works with SQL through SQLPLUS but not with java. Indeed I have to store the data through my application
    In java I get java.sql.SQLException: ORA-19102
    Many thanks in advance,
    Evanela

    Thanks for your answer. I downloaded the JDBC AddressBook application and I found it very usefull. I was able to populate a datalist from a datasource and show it in my application. My problem still remains in the sense that I am unable to show the KPI data in a "custom node" meaning I woul like not only to extract directly the database record to a datalist object but also put the information of a single record in a textbok and a gauge and keep control of paging. I think this is done with the parser in the other examples but I can not figure out how to do it with MySQL and the new Desktop screen designer. Should I use a clip object? or is that managed already by the desktop screen designer? or where can I find an example with the functionality I need?.

  • PSP Flash 6 | XML data storage

    hi all
    I cannot get XML working with the PSP, anybody know how to
    get XML working, is there anything to watch out for?
    I have checked every xml keyword that I have used and they
    are all included in the Flash 6 specification.
    regards
    john

    Flash 6, I am developing in Flash 6 not 7. NF3 6

  • Servlet - xml data storage best practice

    Hello - I am creating a webapp that is a combination of servlets and jsp. The app will access, store and manipulate data in an xml file. I hope to deploy and distribute the webapp as a war file. I have been told that it is a bad idea to assume that the xml file, if included in a directory of the war file will be writeable, as the servlet spec does not guarantee that war are "exploded" into real file space. For that matter, they do not guarantee that the file space is writeable at all.
    So, what is the best idea for the placement of this xml file? Should I have users create a home directory for the xml file to sit in, so it can be guaranteed to be writeable? And, if so, how should I configure the webapp so they it will know where this file is kept?
    Any advice would be gratefully welcomed...
    Paul Phillips

    Great Question, but I need to take it a little further.
    First of all, my advice is to use some independent home directory for the xml file that can be located via a properties file or the like.
    This will make life easier when trying to deploy to a server such as JBoss (with Catalina/Tomcat) which doesn't extract the war file into some directory. In that case you would need to access your XML file which would be residing inside a war file. I haven't tried this (sounds painful) but I suspect there may be security access problems when trying to get the FileOutputStream on a file inside the war??
    Anyway.... so I recommend the independent directory away from the hustle and bustle of the servers' directories. Having said that..... I have a question in return: Where do you put a newly created (on the fly) jsp that you want accessed via your webapp?
    In Tomcat its easy... just put it in the tomcat/webapps/myapp directory, but this can't be done for JBoss with integrated Tomcat (jboss-3.0.0RC1_tomcat-4.0.3).
    Anyone got any ideas on that one?

  • Bringing xml data into flash

    I would like to know how to bring xml data into flash.
    Specifically images that someone can click on the thumbnail and
    view the larger image. please can anyone point me to some tutorials
    or sites that i can start to learn how to do this.
    thanks.

    Hi
    First of all, read every thing you can in Flash Help to get
    to know the different methods of loading XML.
    XML can be loaded with 'built-in' components or parsed in
    Actionscript, the Help files will explain both.
    Next - Google for 'XML Image or Picture Gallery' you'll find
    plenty
    Hope it helps

  • Local data storage with XML vs SQLLite

    Short version:
    I have a mobile app that gathers and stores a large amount of data. The current XML solution (all in one file) is having performance issues as the volume of data increases beyond a certain point.
    Can I be confident that using SQLLite and a local database will be a better option and improve performance?
    Long version:
    I have built a mobile app that is used by my client to collect data.
    When we started the project the amount of data was relatively small. Given that, and given the past experiences of my team, we chose to use an XML file to store the collected data. When the app starts it loads the whole xml file into a set of data objects in memory for use by the app. The data is not loaded again for as long as the app stays running. We then run a routine whenever the app wants to save to the HD that converts all of the data back into XML.
    The data is split into 'projects' and each project naturally has its own xml node. To improve performance when saving, each instance of the Project class stores its loaded node string. Then, when the save routine is called, if the classes data has not been changed it simply returns the original string instead of going through the whole process of re-compiling it.
    Of course this does not change the fact that whenever a save is performed, the whole xml structure must be saved back to the file on the HD.
    The app has now been used in anger for quite some time and we are starting to get reports of performance issues. The main culprit is during loading which only happens once but can apparently now take an exeptionally long time and causes problems during startup to the point where users think it has crashed.
    I am now tasked with trying to improve the data storage for the app. My original reaction was to try breaking down the xml into multiple files which can then we loaded and saved when needed instead of handling everything all at once. I am worried though about the implications of the app trying to handle in excess of 2000 xml files in some cases. It may not be an issue at all but it just stands out to me as something to be concerned about.
    So the best other option that I am aware of is to use SQLLite to save all the data into a local database. I have very little personal experience with sql and databases though so while a lot of the documentation and blog posts I see seem to suggest that this is the way to go for mobile apps with a large amount of data, I cannot be quite certain. The big issue is that I cannot afford to sell the idea of such a radical change (and more importantly the time it would take to implement it) to my client without being quite sure that this will be a valid solution to the problem.
    So my question to you, Flex community, is would you continue to use XML or is SQLLite the better way to go for large amounts of data? Do you think that I would see an improvement by using SQLLite? Additionally, do you have any tips or experience with a similar situation that might be helpful to me?
    Thank you
    Jamie

    I've been very happy using the internal SQLite database with Flex.  You should definitely get much better performance from it.  Just being able to load your data asynchronously if nothing else you should get a great benefit.  The sheer amount of data in your XML file that is being passed around is probably quite a hit (especially on mobile).  Breaking up the XML shouldn't be too crazy to do (as you're already doing it somewhat, I'd imagine, when you're accessing the information from within your app).  Give switching to SQLite a try, but I'd say that's a great place to start.

  • Prefered data storage method for AIR apps?

    So I'm starting on my AIR application journey, in the end I would like to develop applications for Droid.  I'm used to developing for the web and mostly use MySQL, I've been looking at SQLite and XML as data repositories.  I feel that for most of my applications at this point XML files would most likely do the job, but is there a prefered data storage method for AIR applications?
    EDIT:  I've been looking around for a primer on Flash & SQLite interaction if someone could point me in the right direction it would be very thankful.
    Thank you much!

    For document management, I believe simple file/Directory would be sufficient. have files under a file server, with your app do the proper indexing, concurrency etc from that file server folder, which shall properly stores and index the documents.

  • How to search XML data from a HTTPMultiService and display the result on the Spark List

    Hello all,
    I am totally new to Flash Builder and Actionscript and hope someone might be able to help me out. I basically create a mobile app with a single view. The view has a TextInput as a search box and a search button. I conntected a Data/Service using a local XML file and bind the Data to a Spark List. Innitally the List will show nothing until the user enter the search term and hit the button. The List suppose to show the XML data that match the search term.
    Now is my problem. I cannot make the List to show the data that match the search text. The List just shows ALL the data.
    Here are my MXML code:
    <?xml version="1.0" encoding="utf-8"?>
    <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
            xmlns:s="library://ns.adobe.com/flex/spark"
            xmlns:shopping="services.shopping.*"
            title="Search">
        <fx:Script>
            <![CDATA[
                import mx.events.FlexEvent;
                protected function button1_clickHandler(event:MouseEvent):void
                    navigator.popView();
                protected function list_creationCompleteHandler(event:FlexEvent):void
                    getDataResult.token = shopping.getData();
                protected function seach_clickHandler(event:MouseEvent):void
                    getDataResult.token = shopping.getSearchData(searchTxt.text);
            ]]>
        </fx:Script>
        <fx:Declarations>
            <s:CallResponder id="getDataResult"/>
            <shopping:Shopping id="shopping"/>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
        <s:actionContent>
            <s:Button height="79" label="Back" click="button1_clickHandler(event)"/>
        </s:actionContent>
        <s:List id="list" left="0" right="0" top="111" bottom="0"
                creationComplete="list_creationCompleteHandler(event)" labelField="english">
            <s:AsyncListView list="{getDataResult.lastResult}"/>
        </s:List>
        <s:TextInput id="searchTxt" x="80" y="34" width="250" height="49" enabled="true"
                     prompt="search..."/>
        <s:Button id="search" x="338" y="35" width="72" height="49" label="s"
                  click="seach_clickHandler(event)"/>
    </s:View>
    Here is the _Super_Shopping.as file:
    * This is a generated class and is not intended for modification.  To customize behavior
    * of this service wrapper you may modify the generated sub-class of this class - Shopping.as.
    package services.shopping
    import com.adobe.fiber.core.model_internal;
    import com.adobe.fiber.services.wrapper.HTTPServiceWrapper;
    import com.adobe.serializers.xml.XMLSerializationFilter;
    import mx.rpc.AbstractOperation;
    import mx.rpc.AsyncToken;
    import mx.rpc.http.HTTPMultiService;
    import mx.rpc.http.Operation;
    import valueObjects.Shop;
    [ExcludeClass]
    internal class _Super_Shopping extends com.adobe.fiber.services.wrapper.HTTPServiceWrapper
        private static var serializer0:XMLSerializationFilter = new XMLSerializationFilter();
        // Constructor
        public function _Super_Shopping()
            // initialize service control
            _serviceControl = new mx.rpc.http.HTTPMultiService();
             var operations:Array = new Array();
             var operation:mx.rpc.http.Operation;
             var argsArray:Array;
             operation = new mx.rpc.http.Operation(null, "getData");
             operation.url = "assets/data/shopping.xml";
             operation.method = "GET";
             operation.serializationFilter = serializer0;
             operation.properties = new Object();
             operation.properties["xPath"] = "/::shop";
             operation.resultElementType = valueObjects.Shop;
             operations.push(operation);
             operation = new mx.rpc.http.Operation(null, "getSearchData");
             operation.url = "assets/data/shopping.xml";
             operation.method = "GET";
             operation.resultFormat = "text";
             argsArray = new Array("item");
             operation.argumentNames = argsArray;
             operation.properties = new Object();
             operation.properties["xPath"] = "/::shop";
             operation.resultElementType = valueObjects.Shop;
             operations.push(operation);
             _serviceControl.operationList = operations;
             preInitializeService();
             model_internal::initialize();
        //init initialization routine here, child class to override
        protected function preInitializeService():void
          * This method is a generated wrapper used to call the 'getData' operation. It returns an mx.rpc.AsyncToken whose
          * result property will be populated with the result of the operation when the server response is received.
          * To use this result from MXML code, define a CallResponder component and assign its token property to this method's return value.
          * You can then bind to CallResponder.lastResult or listen for the CallResponder.result or fault events.
          * @see mx.rpc.AsyncToken
          * @see mx.rpc.CallResponder
          * @return an mx.rpc.AsyncToken whose result property will be populated with the result of the operation when the server response is received.
        public function getData() : mx.rpc.AsyncToken
            var _internal_operation:mx.rpc.AbstractOperation = _serviceControl.getOperation("getData");
            var _internal_token:mx.rpc.AsyncToken = _internal_operation.send() ;
            return _internal_token;
        public function getSearchData(item:String) : mx.rpc.AsyncToken
            var _internal_operation:mx.rpc.AbstractOperation = _serviceControl.getOperation("getSearchData");
            var _internal_token:mx.rpc.AsyncToken = _internal_operation.send(item);
            return _internal_token;
    The getSearchData() supposed to return XML data that match the search text, but it doesn't. Can anyoen help?
    Thank you!

    Hi,
    are you able to change dynamically the  operation.url = "assets/data/shopping.xml";?
    i need to do that based on the users input.
    Thanks in advance,

  • XML data into Combo & List

    Hi
    I am too new to this and still tring to learn. Well here is what I am into. I am trying to make a simple product catalog, using native components
         a combobox to display DISTINCT health issues
         a listbox to display the products associated to the selected health issue item in ComboBox
         a textarea to display complete information about the selected product in listbox
    Data comes from single external xml file.
    I was able to start off with Combo, but I don't know how to display DISTINCT ITEMS IN IT? Now it display all items including duplicates. Then I added eventlistener to Combo, which on change, the data for selected item is displyed in Textarea, but i don't know how to hook this to List component.
    All files available here:
    https://docs.google.com/folder/d/0ByHOlDbL5njbX1FFd1UtTFNzMTg/edit
    Sure some of you can do it so easy. Appreciate your time and help.
    Thank you
    Kristtee

    Filter the XML before using it to create your dataProvider http://joshblog.net/2007/05/17/filter-xml-data-with-e4x-in-flash-part-2/

  • Trying to Insert an XML Element into XML data stored in CLOB column

    Hi all,
    My ORACLE DB version is:
    ('Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production');
    ('PL/SQL Release 11.2.0.2.0 - Production');
    ('CORE 11.2.0.2.0 Production');
    ('TNS for Linux: Version 11.2.0.2.0 - Production');
    ('NLSRTL Version 11.2.0.2.0 - Production');
    I have this XML data stored in a CLOB column:
    <Activity>
         <Changes>     
         </Changes>
         <Inserts>     
         </Inserts>
         <Definition>     
         </Definition>
         <Assignment TYPE="Apply">     
         </Assignment>
         <Spawned>
              <Activity>576D8CD9-57A1-8608-1563-8F6DC74BDF3C</Activity>
              <Activity>11226E79-5D24-02EB-A950-D34A9CCFB3FF</Activity>
              <Activity>DAA68DC0-CA9A-BB15-DE31-9596E19513EE</Activity>
              <Activity>93F667D6-966A-7EAD-9B70-630D9BEFDDD2</Activity>
              <Activity>FA63D9D3-86BB-3FF0-BE69-17EAA7581637</Activity>
         </Spawned>
         <SpawnedBy>AFC49BD4-5AA7-38C0-AE27-F59D16EE1B1C</SpawnedBy>
    </Activity>
    I am in need of some assistance in creating an update that will insert another <Activity>SomeGUID</Activity> into the <Spawned> parent.
    Any help is greatly appreciated.
    Thanks.
    Edited by: 943783 on Dec 14, 2012 12:58 PM

    See XML updating functions : http://docs.oracle.com/cd/E11882_01/appdev.112/e23094/xdb04cre.htm#i1032611
    For example :
    UPDATE my_table t
    SET t.my_clob =
          XMLSerialize(document
            insertChildXML(
              XMLParse(document t.my_clob)
            , '/Activity/Spawned'
            , 'Activity'
            , XMLElement("Activity", 'Some GUID')
    WHERE ...
    ;Although it works, there's overhead introduced by parsing the CLOB, then serializing again.
    Is there any chance you can change the CLOB to SECUREFILE binary XMLType storage instead?
    You would then be able to benefit from optimized piecewise update of the XML and improved storage.

  • Non-server data storage

    A friend of mine is developing a database for a specific environment:
    A small number of peer-to-peer networked Windows computers in a small office, with no dedicated servers - each computer acting as an individual's workstation. They want a "central" database to store client information etc, with an interface they can all use at once to access and change the data.
    Given the nature of the environment, my first thought was that some sort of file-based data storage (not requiring a server process) would be most appropriate - Access, csv, XML....but I'm not intricately familiar with JDBC support for these mechanisms, so wasn't sure what to recommend specifically.
    They are not willing/able to spend any money on this solution, so it must use the current environment. Can someone recommend a data storage method and point me to an appropriate JDBC driver?
    Oh, and while I have your attention - anybody know of a good CSV parser? I'm currently splitting a line of data by commas, but it's also splitting strings with commas in them...

    A friend of mine is developing a database for a
    specific environment:
    A small number of peer-to-peer networked Windows
    computers in a small office, with no dedicated servers
    - each computer acting as an individual's workstation.
    They want a "central" database to store client
    information etc, with an interface they can all use at
    once to access and change the data.
    based on this i have a non-Java solution to suggest.
    use MS-Access and IIS to develop and deploy an intranet.
    there are several pros to this solution that i see
    - You can develop and deploy an intranet using web browsers as clients very quickly and relatively cheaply
    - an intranet (series of web pages) vs. a full blown application may well be easier to make changes to
    - having the data in a RDBMS (Access) which will be cost effective in this case also will make it relatively simple to upgrade port the system later
    now i like programming in java as much as the next person but from your requirements it sounds like writing an application might be overkill. in my experience doing an intranet like this is a pretty good solution.. you don't have to install anything on the clients... you already have the software for the server (if you don't have IIS most versions of Windows now have PWS or Personal Web Server which will work for this)... the important thing is to have a good database design so that you can make changes or port the client easily later if you need to.

  • XML Data Sets and IE8

    I have an issue with Spry XML Data sets that is driving me nuts.
    The setup is quite straightforward. I have a PHP script which submits a SOAP request, the result of which is pure XML. I echo this XML out as the result of the script.
    I have another page on which is one or more Spry XML Data Sets. These data sets use the previous script as the source. I know this works OK because when i 'Get Schema' in the XML dataset dialog in Dreamweaver, the schema is properly displayed. This page also has a Spry Table on it, which uses the dataset as the source. There is nothing else on the page at all.
    Now, when I preview this page in Firefox, Chrome, Opera or Safari, it displays fine. However, when I preview it in IE, the table briefly flashes up then disappears. A quick look at the source of the page shows the HTML all laid out very licely, but the Spry fields still show with their placeholders (e.g. {Balance}) instead of the actual value. Im left with a totally blank page in IE.
    I have tried running in compatibility mode with no effect. I found a posting on Experts Exchange (yuk!) where someone else was having the problem but this turned out to bedue to badly formed XML. I have run my XML though XMLSpy and several online validators and it checks out every time.
    Any ideas? I am slowly losing the will to live....
    Si

    Hi,
    I'm trying to debug the same problem...I think.The pages work in firefox on PC & MAC but stop with the {data_name} in IE on both PC & MAC.
    I'm using Dreamweaver CS3 with ADDT. I've read the posts about adding the content-type to my file that ADDT created for me just before the XMLExport, so I've added that to the get_menu_1_info.php file (see lines 42-46). I've peeked into the XMLExport.class.php file to see that the Execute function is supposedly already sending the header info (see line 223). But I'm not getting the data into IE.
    Any help would be appreciated!
    here's where you can see the page:
    https://hbblearning.org/Takv3uMYsX7cVK5eRo/newcomer_info.html
    here's where I generate the xml file to be consumed:
    https://www.hbblearning.org/get/get_menu_1_info.php
    I've attached the files for you to see.

  • Loading new xml data into a already xml populated image display

    Hi everybody,
    I have a question about loading new xml data into a already xml populated image gallery.
    So I have my gallery set up so it calls some xml when it first loads. What I would now like to do is load different sets of images via a different xml sheet via the click of a button.
    So for example the loaded gallery already has all thumbs loaded and user can click on them to view the full size image. So next instead of the user having to close this gallery to allow a new gallery to open with a different set of pictures I would just like to have a button. This button will unload the existing thumbs from the gallery and load in new ones from a different xml file.
    If anybody can help me with this it would be great as I am still on a steep learning curve with AS3.
    Here is my AS3
    var xmlPath:String = "pictures.xml";
    var xml:XML;
    var loader = new URLLoader();
    loader.load(new URLRequest(xmlPath));
    loader.addEventListener(Event.COMPLETE, xmlLoaded);
    function xmlLoaded(e:Event):void
         if ((e.target as URLLoader) != null )
              xml = new XML(loader.data);
              createMenu();
    var numberOfItems:uint = 0;
    var menuItems:Array = new Array();
    function createMenu():void
              numberOfItems = xml.items.item.length();
         var count:uint = 0;
              for each (var item:XML in xml.items.item)
              var imageLoader=new Loader();
              var menuItem:MenuItem = new MenuItem();
              menuItem.addChild(imageLoader);
              imageLoader.load(new URLRequest(item.url));
              menuItem.linkTo = item.linkTo;
              menuItem.mouseChildren = false;
              menuItem.addEventListener(MouseEvent.CLICK, itemClicked);
              menuItems.push(menuItem);
              addChild(menuItem);
              count++;
    function ***():void
         //menuItems.sortOn("zpos3D", Array.NUMERIC | Array.DESCENDING);
         for (var i:uint = 0; i < menuItems.length; i++)
              setChildIndex(menuItems[i], i);

    Thanks so much for the reply Andrei1
    I think maybe my lack of knowledge when it comes to AS3 is not helping me at the moment because I thought I understood the code you supplied but there is something not going quite right.
    So I messed around with the code and added the new_loaded_thumbs_btn to load in the "new_pictures.xml" but I am def doing something wrong.
    import flash.ui.ContextMenuItem;
    var xmlPath:String = "pictures.xml";
    var xml:XML;
    var numberOfItems:uint = 0;
    var menuItems:Array = new Array();
    var loader = new URLLoader();
    loader.addEventListener(Event.COMPLETE, xmlLoaded);
    loadXML("pictures.xml");
    new_loaded_thumbs_btn.addEventListener(MouseEvent.CLICK, loadXML);
    function loadXML(path:String):void {
         loader.load(new URLRequest("new_pictures.xml"));
    function loadXML(path:String):void {
         loader.load(new URLRequest(path));
    function xmlLoaded(e:Event):void
         xml = new XML(loader.data);
         createMenu();
    function createMenu():void
         clearMenu();
         numberOfItems = xml.items.item.length();
         var count:uint = 0;
         var imageLoader;
         var menuItem:MenuItem;
         for each (var item:XML in xml.items.item)
              imageLoader = Loader();
              menuItem = new MenuItem();
              menuItem.addChild(imageLoader);
              imageLoader.load(new URLRequest(item.url));
              menuItem.linkTo = item.linkTo;
              menuItem.mouseChildren = false;
              menuItem.addEventListener(MouseEvent.CLICK, itemClicked);
              menuItems.push(menuItem);
              addChild(menuItem);
              count++;
         sortChildren();
    // removes previously placed objects
    function clearMenu():void {
         var menuItem:MenuItem;
         while (menuItems.length > 0) {
              menuItem = menuItems[0];
              removeChildAt(getChildIndex(menuItem));
              menuItem.shift();
    function sortChildren():void
         //menuItems.sortOn("zpos3D", Array.NUMERIC | Array.DESCENDING);
         for (var i:uint = 0; i < menuItems.length; i++)
              setChildIndex(menuItems[i], i);
    When the image display 1st loads it displays the new_pictures.xml thumbs which I thought would load through my new button when clicked.
    And there was me thinking I was getting the hang of AS3.
    Could you please point me in the right direction in what I am doing wrong,
    Thanks for your time and effort in advance

  • XML data not displayed on external applications (Adobe, PowerPoint, Word)

    Hi,
    I have imported an XML file into Xcelsius using the XML data connection button in Xcelsius 2008 SP1.
    I would like to test whether the model is correctly picking up the data when XML file is updated.
    The XML file is stored locally on my PC.
    I'm able to view and refresh the data in Preview mode and in the .SWF file but when exporting to Adobe, PowerPoint or Word, I get #2148 error on opening.
    I did add the path to the swf file and xml file in the Flash Player security settings with no success.
    Any suggestions welcome
    Best regards,
    Jenni Jacob

    Hi Jenni,
    Adobe PDF usually works because like Xcelsius it allows the SWF to load data from anywhere so I am not sure why that one would not work...
    When you export to PowerPoint or Word that probably counts as a different SWF so try adding the folder where the PPT/DOC lives as trusted instead.
    When I am in a VM I tend to add C:\ folder as trusted (meaning I can run a SWF anywhere on my C drive in the VM with trusted permissions).
    Regards,
    Matt

Maybe you are looking for