Select to view content in your preferred language

can't compile widgets reliably

605
8
12-01-2010 11:33 AM
GeorgiannaStrode
New Contributor
I am able to compile components like MapManager.mxml and I can compile some widgets.  But others I can't.

For example, I copied the widgets/Search folder to widgets/Search2 (I did not edit any of ESRI's code) and cleaned and rebuilt, and there is no .swf in the bin-debug folder.  All of the untouched ESRI widgets compile fine.  I referenced Search2 in my config.xml just in case that acts as a trigger of some sort.

Is there some sort of "registration" process that you have to go through to tell it to compile?  If I remove everything from bin-debug and rebuild it will put the folder there and the xml file but no .swf.  Just reiterating that the mxml files are unedited so there can't be any code problem.

Any help is greatly appreciated.
Tags (2)
0 Kudos
8 Replies
RobertScheitlin__GISP
MVP Emeritus
Georgianna,

   Yes you have to add the widgets mxml file to your flex projects modules list for a swf to be built. To do this right click on your flexviewer project in the package explorer window and choose properties then click flex modules and browse to the widget's mxml file and add it.
0 Kudos
GeorgiannaStrode
New Contributor
Robert, thanks a BUNCH!  I would have never found that.
0 Kudos
vinaysharma
New Contributor
Georgianna,

   Yes you have to add the widgets mxml file to your flex projects modules list for a swf to be built. To do this right click on your flexviewer project in the package explorer window and choose properties then click flex modules and browse to the widget's mxml file and add it.


I also have same problem, even i followed your steps but swf file is not creating. i don't know why. after add swf and xml files should be create but not creating. plz tell me where i am wrong and what should i do?
I am trying to add streetview.mxml.

thanx
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Vinay Sharma,

   If after you have added streetview.mxml to your flex project modules list and it is still not getting a swf built than the reason is that there is an error in the code or your configuration that is preventing it. You need to look for errors, to do this go to the window menu and click Problems and see what is listed there.
0 Kudos
vinaysharma
New Contributor
Vinay Sharma,

   If after you have added streetview.mxml to your flex project modules list and it is still not getting a swf built than the reason is that there is an error in the code or your configuration that is preventing it. You need to look for errors, to do this go to the window menu and click Problems and see what is listed there.


I get the following error when compiling: "Unable to locate specified base class 'com.esri.viewer.BaseWidget' for component class 'widgets.FrStreetView.FrStreetView'. FrStreetView.mxml /Flexviewer2_1/src/ widgets/FrStreetView

Problem Displayed Below:

Description: 
Unable to locate specified base class 'com.esri.viewer.BaseWidget' for component class 'widgets.FrStreetView.FrStreetView'.
Resource Path:
FrStreetView.mxml /flexproj1/src/widgets/FrStreetView
Location Type:
Unknown Flex Problem
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Vinay Sharma,

   So the big question is are you using FlexViewer 2.1? You can not take a widget developed for FlexViewer 2.x and use it in the Sample Flex Viewer 1.x or a non FlexViewer project there are to many dependencies that you will have to re-code.
0 Kudos
vinaysharma
New Contributor
Vinay Sharma,

   So the big question is are you using FlexViewer 2.1? You can not take a widget developed for FlexViewer 2.x and use it in the Sample Flex Viewer 1.x or a non FlexViewer project there are to many dependencies that you will have to re-code.


Dear Sir,
          Exactly I am using Flex Viewer 2.1. If I can't implement to same street view module in my applicationthen, then Please advice me to best way to implement streetview in my module and How?

Thanx
0 Kudos
vinaysharma
New Contributor
Vinay Sharma,

   So the big question is are you using FlexViewer 2.1? You can not take a widget developed for FlexViewer 2.x and use it in the Sample Flex Viewer 1.x or a non FlexViewer project there are to many dependencies that you will have to re-code.


Problem Solved........

Now I am able to used Street View Module in my Application.
0 Kudos