Select to view content in your preferred language

widget xml file is ignored

801
5
05-27-2010 04:41 PM
NeoGeo
by
Frequent Contributor
I am hoping this is a fairly generic problem and that I am doing something simple/stupid that I can learn from.  I added yet another widget someone else wrote and it seems that the xml file is somehow getting compiled in, because once the project has been build and exported, all changes to the xml file are ignored.  I even deleted it and the app acted like nothing had changed and still works with the settings that were in it at compile time.  I deleted the browser cache, flash cache, and even restarted IIS to make sure it wasn't being cached somehow.  This widget uses two mxml's and two xml files.  I added both mxml's as modules (which I am not sure is the correct thing to do).  Only one mxml/xml is entered in widgets section of the config.xml.  I am just trying to learn a bit more here as I am not sure this is some basic error I have made in building the project or it is a problem with the widget itself. 

In case you are wondering it is an exif image viewer widget that was posted on the old forums.

Thanks!
Tags (2)
0 Kudos
5 Replies
RobertScheitlin__GISP
MVP Emeritus
J oN,

    Are you running from the debugger in Flex Builder? If so what does the exifCatalog.xml in the bin-debug look like? Does it contain your changes? Have you run a "clean" from the project menu?
0 Kudos
NeoGeo
by
Frequent Contributor
I am mostly just trying to learn from this.  There are some things one cannot learn from documentation. 

Clean did not make any difference.  I have not been running from the debugger.  I have been exporting a release build and copying to a server running ArcGIS server and then doing some debugging in Firebug.  I am thinking it is just a problem with the widget.  It has lots of problems.  It was the one at the bottom of this post and probably just meant to be a proof of concept:
http://forums.esri.com/Thread.asp?c=158&f=2421&t=276876
It probably should be rewritten to just read all the images in a given folder rather than having to set up a path for each one in the exifcatalog.xml.  It just seems like I must be making some basic error in building it for the xml file to be compiled in somehow.  The author had the widget in a different folder called "mywidgets", but after build, the exifcatalog.xml is MOVED to the normal ESRI widgets folder, exifreader.xml and exifthumbnail.swf are COPIED to the normal widgets folder, and exifreader.swf stays where it started in mywidgets.

Thanks for being such a great help.  It is often so difficult to find anyone who has a clue about this stuff.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
J oN,

    Just to test a theory try copying the exifCatalog.xml file to the main folder (i.e. the same folder as the index.html) and give that a try.

Robert
0 Kudos
NeoGeo
by
Frequent Contributor
I cut the exifCatalog.xml from the widgets folder and put it into the application root folder.  I checked to make sure there weren't any other copies hidden anywhere in the app and there are not.  Still, the app uses what was in the xml at build time and ignores the xml file completely regardless of whether I move it, delete it, or change it. 

Would you say that for a widget that uses two mxml's and two xml files, that both mxml's are registered as modules as you do normally when there is only one?  In the config.xml, you specify the xml file that goes with the main mxml/swf which is in the menu, but how is it supposed to know about the second xml?  That may be where I am going wrong.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
J oN,

   The exifCatalog.xml file is called from the exifreader.swf using this line
<mx:XML id="xml" source="exifCatalog.xml" />


so it looks like it is expecting it in the same folder as the exifreader.swf is in.

Robert
0 Kudos