Select to view content in your preferred language

Flex Build Question

1238
9
06-18-2010 12:48 PM
BradOleson
Emerging Contributor
I have a weird thing occurring with Flash Builder 4 while working on customizing and testing:

If I clean the project then run it ("Project->Clean...", then the green "Run Index" button) the project runs in debug mode, but ignores a couple specific changes I've made; most notable is the selected index on the PrintPDF widget.  In this case "Landscape" is selected, even though "Portrait" should be (index 0 vs index 1).

If I change any line of code and run the project WITHOUT the clean, it runs the code as currently entered - meaning the index for the combo is Portrait, as it should be per the code.

If I export a release build it acts the same as the "cleaned" build.

There are other oddities when the PDF is actually produced using each of these methods, but I'm not sure adding that would be helpful right now.

What is the difference in the two methods of running this in debug mode?  The "Clean first" seems to be seeing something old that is cached?  I'm pretty confused and welcome anyone's thoughts on this. 

I know that this MAY be a Flash Builder forum question, but maybe someone here has seen it before.

Thanks!

Brad
Tags (2)
0 Kudos
9 Replies
ReneRubalcava
Esri Frequent Contributor
When you do the clean, are you cleaning all projects or just your main one? You can view it delete the contents of your bin-debug and then recompile to it. Not sure why it wouldn't catch recent changes. FlashBuilder is extremely buggy, and I have had issues that required I clean a project numerous times. Personally, it's my least favorite IDE to work in. I'm not familiar with the Print Widget, but is that change made in the code or a config.xml file? If it's in xml, you can delete that from your bin-debug, and do a clean again, it should work. Should being the relative term.
0 Kudos
BradOleson
Emerging Contributor
I only have one project, so just the main one.

The changes are being made in the code, not the .xml file.

I'm quite perplexed but continuing to dissect exactly where in the code it seems to be having issues.  It just makes debugging really hard when you can't be sure if you are seeing your results, or some cached stuff from a previous run.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Brad,

  I have help with an issue like this before and it tuned out that that person had some swfs in the src folder and you should never have any compiled swfs in your src folder or else those get copied to the bin-debug and/or bin-release folder when you clean. It that your case? If so just delete the swfs from your src folders
0 Kudos
BradOleson
Emerging Contributor
I'm pretty sure you've hit it dead on the head, Robert! I'm going to have to wait til Monday to check, but I think that may be the case. I will post back Monday to confirm.

Brad
0 Kudos
BradOleson
Emerging Contributor
That indeed seemed to be the issue.  I have removed the offending .swf files.  However, now I get the "spinning clock" when my project loads in debug mode.  Everything seems to be functioning, but the spinning cursor is omni-present.

Brad
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Brad,

   So is it safe to assume you ran clean again after you deleted the swfs from your src folder? Is the widget that is producing the spinning clock listed in the Flex Projects modules list? If so try removing it and then re-adding it to the list.
0 Kudos
BradOleson
Emerging Contributor
I removed it, built the project, then readded it and built the project again.  Still getting the spinning clock.  Any other thoughts?

Brad
0 Kudos
BradOleson
Emerging Contributor
Nevermind...that turns out to be the solution after all.  There were TWO widgets with SWF files in the widgets folder, but I only removed the one I was concerned about working with.  WHen I repeated the process on the other widget it solved the issue.

Thanks, Robert!

Brad
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Brad,

   When you get the spinning clock that usually means that the swf the the config.xml has specified is not there, or you have some errors in the code.

1. check your bin-debug folder and see if the swf is there for that widget.

2. check the problems window in flex builder for error (not warnings).
0 Kudos