|
POST
|
Robert, I can consitantly make you live site give the exclamation point of death, but not a consistant method (or rather, not a consistant number of clicks). However, if I Turn on the zoning layer, select it from identify and select by rectangle, it will return a selection. If I start clicking like mad on the results and not quite letting it "finish" drawing after it pans, THEN try to move the mouse up to the top of the widget (like you were going to switch to input mode rather than results) OR hover the mouse over the map somewhere (other than over the identify widget), bam, I get the exclamation point. Seems to be related to a mouse_over event or something as I can only make it happen when I have the mouse going all over the place while "panning/zooming to" a feature. R_ Looks like I can do it with the land use layer also, but not as "quickly". at first, thought it had something to do with the bug on dynamic layers losing (or getting null geometry) once you click off the feature, but, I can make it happen on the land use layer "eventually" also.
... View more
11-20-2012
03:16 PM
|
0
|
0
|
3758
|
|
POST
|
Seems I always get a similar message when I use the TOC widget: warning: The class widgets.TOC.toc.tocClasses.LegendDataClassItem has been used in a call to net.registerClassAlias() in _TOCWidget_FlexInit. This will cause widgets.TOC:TOCWidget to be leaked. To resolve the leak, define widgets.TOC.toc.tocClasses.LegendDataClassItem in the top-level application. But have not got the exclamation point of death.... R_
... View more
11-20-2012
02:49 PM
|
0
|
0
|
571
|
|
POST
|
Any ideas? Seems that since it takes the export options as input, one should be able to "modify" it or change that setting. In fact, seems that this should be a printwidget.xml config option. deault 96 dpi is decent for a monitor, but way sub-par for most print jobs. Seems that 266 should be the default as not many printers have a linefeed of more than 133 and would maximize most printer capabilties. If nothing else, anyone know where the JSON string for the printTask is being generated? R_
... View more
11-20-2012
10:16 AM
|
0
|
0
|
3118
|
|
POST
|
Add this to the default.css: esri|PopUpRenderer
{
skin-class: ClassReference("com.esri.ags.skins.PopUpRendererSkin");
} and this modification to the PopUpRendererSkin.mxml: for each (var fieldInfo:PopUpFieldInfo in popUpInfo.popUpFieldInfos)
{
var fldName:String = formattedAttributes[fieldInfo.fieldName];
if (fieldInfo.visible && hostComponent.featureLayer.url == "http://gis.ncdcr.gov/ArcGIS/rest/services/NC_Surveyed_Only/MapServer/0"
&& fieldInfo.fieldName == "County" && fldName!= "Bertie" && fldName!= "Brunswick")
{
validMediaInfos = null;
}
if (fieldInfo.visible && formattedAttributes[fieldInfo.fieldName] && formattedAttributes[fieldInfo.fieldName] != " ")
{
var fieldLabel:Label = new Label();
does it. The idea being to make it fail this test just below the above code if (validMediaInfos && validMediaInfos.length > 0)
{
vGroup.addElement(mediaBrowser);
mediaBrowser.attributes = graphic.attributes;
mediaBrowser.formattedAttributes = formattedAttributes;
mediaBrowser.popUpFieldInfos = popUpInfo.popUpFieldInfos;
mediaBrowser.popUpMediaInfos = validMediaInfos;
}
so that the medias don't get added to the vGroup. (again, the red code removes items with null or empty values from the popup, so remove that if you want to see no values.) R_ Of course this will still give you the broken link/preview for the sites in the two counties that do NOT have a photo (noticed there are a few). Thought one could get fancy and test to see if the jpeg file exists, if so, then add it. However, there is no http://www.hpo.ncdcr.gov/crossdomain.xml file, so it doesn't allow access to the images from index.swf so throws a debugger error every time. However, if it does exist, it will still preview it and give you the link? Not sure why, almost as if the crossdomain.xml doesn't apply from within the popup? Once clicked, it opens in a separate browser, not within flex, so that makes sense. Don't really understand why I get the sandbox violation and still load the preview/link.
... View more
11-16-2012
10:41 PM
|
0
|
0
|
613
|
|
POST
|
Another thought, but I'm home now and won't be around FlashBuilder until Monday at earliest (possibly the following Monday) so cant test it out so I thought I'd throw it at ya in case you want to try. You may be able to utilize the eSearchWidget for this. Have not tried it, but you could try to enter the same layer in twice. One with your expression that you want, the other would select everything <> to your expression. You can then configure the popup fields for each config layer separately with their respective fields. Have it preload=open and size it so it's just the "active" button (or whatever you want to see on the GUI). Then disable everything except the graphic search (mappoint) button, and make active by default, and keep active. Disable autozoom if you want it to behave more like a "regular" popup, otherwise, might actually be nice as the normal popup will "obscure" itself on the margins if the feature clicked is near the edge, and autozoom (or set the zoomscale so that it more auotpans) to feature option would be nice on the popup (In case the developers are reading this autopantocenter for popup feature option would be great 🙂. Have not tried it, so don't know if you can do this with the "same" feature layer in the search.xml more than once, but it is pretty robust widget, so is worth a try. Theory is that since the eSearch doesn't actually search the graphics loaded on the map, but rather the feature layer you list in the config, and, each layer has a <definitionexpression/>tag. In "theory", if you click on a feature that doesn't match the definitionexpression, it should match the "other" layers query and pull the popup configed for that layer. If it meets the criteria, the feature will be there and will show the popup fields configured for that layer. This is why the two layers definitions queries would have to be mutually exclusive. (might even be able to do something like defquery1 = sometest, and defquiery2 = NOT(sometest) ) If you want to test, this is what I was thinking for the eSearchWidget.xml: <?xml version="1.0" ?>
<!-- See Enhanced Search Widget XML Configuration.pdf for detailed explanation -->
<configuration>
<layers>
<layer>
<definitionexpression>(County = 'Brunswick') OR (County = 'Bertie')</definitionexpression>
<enableexport>false</enableexport>
<name>NC Surveyed Only</name>
<url>http://gis.ncdcr.gov/ArcGIS/rest/services/NC_Surveyed_Only/MapServer/0</url>
<expressions/>
<graphicalsearchlabel>Click for Info</graphicalsearchlabel>
<spatialsearchlayer>false</spatialsearchlayer>
<titlefield>Site_ID</titlefield>
<fields all="false">
<field name="Id" alias="Id" numberformat="2|,|." />
<field name="Staus" alias="Staus" gridfield="false" />
<field name="Site_Name" alias="Site_Name" gridfield="false" />
<field name="Quad_Name" alias="Quad_Name" gridfield="false" />
<field name="Notes" alias="Notes" gridfield="false" />
<field name="DESCRIPTIO" alias="DESCRIPTIO" gridfield="false" />
<field name="YearSurvey" alias="YearSurvey" gridfield="false" />
<field name="YearUpdate" alias="YearUpdate" gridfield="false" />
<field name="County" alias="County" gridfield="false" />
<field name="Density" alias="Density" gridfield="false" />
<field name="HDstatus" alias="HDstatus" gridfield="false" />
</fields>
<links/>
<zoomscale usegeometry="true" zoompercent="1"></zoomscale>
<autoopendatagrid>false</autoopendatagrid>
<queryattachments>false</queryattachments>
<relates/>
<symbology>
<simplefillsymbol color="0x0000ff" alpha="0.5">
<outline color="0x00ffff" alpha="0.8" width="2" />
</simplefillsymbol>
</symbology>
</layer>
<layer>
<definitionexpression>NOT((County = 'Brunswick') OR (County = 'Bertie'))</definitionexpression>
<enableexport>false</enableexport>
<name>NC Surveyed Only</name>
<url>http://gis.ncdcr.gov/ArcGIS/rest/services/NC_Surveyed_Only/MapServer/0</url>
<expressions/>
<graphicalsearchlabel>Click for Info</graphicalsearchlabel>
<spatialsearchlayer>false</spatialsearchlayer>
<titlefield>Site_ID</titlefield>
<fields all="false">
<field name="Id" alias="Id" numberformat="2|,|." />
<field name="Staus" alias="Staus" gridfield="false" />
<field name="Site_Name" alias="Site_Name" gridfield="false" />
<field name="County" alias="County" gridfield="false" />
</fields>
<links/>
<zoomscale usegeometry="true" zoompercent="1"></zoomscale>
<autoopendatagrid>false</autoopendatagrid>
<queryattachments>false</queryattachments>
<relates/>
<symbology>
<simplefillsymbol color="0x0000ff" alpha="0.5">
<outline color="0x00ffff" alpha="0.8" width="2" />
</simplefillsymbol>
</symbology>
</layer>
</layers>
....................................
<spatialrelationships>
<keepgraphicalsearchenabled>true</keepgraphicalsearchenabled>
<autozoomtoresults>true</autozoomtoresults>
<popupsdisabled>false</popupsdisabled>
<enabledatagridinteractionwithwidget>false</enabledatagridinteractionwithwidget>
<toleranceforpointgraphicalselection>6</toleranceforpointgraphicalselection><!-- value is in screen pixels -->
<tolerancebydefault>false</tolerancebydefault>
<spatialreference>102100</spatialreference>
<zoomscale>2400</zoomscale>
<geometryservice>http://tasks.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer</geometryservice>
<csvseparator>,</csvseparator>
<disablebuttons>text,result,spatial,grid,datagrid</disablebuttons><!--possible values one or more not all four search types comma separated text,graphic,spatial,grid,datagrid -->
<defaultselectionoption>graphicalInput</defaultselectionoption><!--possible values only one graphicalInput or textInput or spatialInput -->
<enabledrawgraphicbutton>true</enabledrawgraphicbutton>
<enablebuffergraphicbutton>true</enablebuffergraphicbutton>
<selectedgraphicaltool>mappoint</selectedgraphicaltool><!-- possible values are extent or polygon or mappoint or polyline or nothing -->
<multipartgraphicsearch>false</multipartgraphicsearch>
<floatorfixed>float</floatorfixed><!-- possible values are fixed and float -->
<relatetooltip>Show Relates</relatetooltip>
<relateicon>widgets/eSearch/assets/images/i_relate.png</relateicon>
....................................................
That is kind of what I am thinking, of course, this only the relevant parts, not complete xml. I don't see a photo field, so not sure where you store that info, so I just made it so if it's NOT one of the two counties listed, it should give popup with "fewer" fields, if is in one of the two counties, should give popup will all the fields. (If this works, AND if I didn't make any stupid typos ) If you try and it doesn't give errors, but doesn't work right, would look into the definitionexpression coding. Would be my most likely mistake other than typos. Also, I see you are not running a geometry server, I get better "faster" results with queries/searches, etc that utilize it if using my own rather than the default. Just in case you want to try. One nice thing about it is that Robert has written it so that everything I mentioned can be done with the eSearchWidget.xml file and no compiling needed (well, again, "if" it can be done ) R_ now that I typed that all up, not sure you can get around having to choose one of the search layers from a dropdown first. Don't know if it can be configed to search both layers, even with same name, at once as I suspect it will put them both in a dropdown.
... View more
11-15-2012
07:45 PM
|
0
|
0
|
2269
|
|
POST
|
Rhett, This confusion is why I was hesitant about adding the "all" to the unique value list when you asked for it. So what I ended up doing is when I see the all chosen in the unique value dropdown I just do a 1=1 query (basically giving you everything as that is what all unique values would be). I see that you are adding "all" to the list, but the query is sending "allu" and when it sees "allu" it sends "1=1". Couldn't one just modify the "all" to something like "all values" and the query to "__allvals__" (or something that will probably never be in the data like "allu" ;o), that way, if the value of "all" is in the data, the pagingquery will find it and add it to the list but you could always select the "all values" option also. As far as the uniquevalsfromfield adding a blank I had this fixed at one point them made some more code changes to account for a possible empty string value being in the data and I broke it again. But I now have it fixed again. Please re-download the widget. So, did you have to un-do this "fix" to get it working correctly as I see we can not search for empty strings (or spaces or nulls) as a value using the uniquevals or userlist options. (uniquevalsfromfields no longer captures the NULL values) BTW Version 3.0.14f is now available with the fix for the first query layer having multiple uniquevalsfromfields Yep, seems to be working fine. However, in this version if one clicks on the Clear button before a search, it throws a null values error (at least with debugger flashplayer). If ANY search has been performed, even if cleared, then you can hit the clear button all you want without the error. also, it appears that if you only have one search layer (either layer(s) or table(s)), you do not get the new "add to selection", "remove from", etc. options. R_
... View more
11-15-2012
12:24 PM
|
0
|
0
|
2031
|
|
POST
|
Andrew, It appears as if the popupconfig.xml info is sent along on click to the popuprenderskin if you add one. If you look at the link in my previous post, will give you an idea, then I have modified it like such: for each (var fieldInfo:PopUpFieldInfo in popUpInfo.popUpFieldInfos)
{
if (fieldInfo.visible && (hostComponent.featureLayer.url == "http://gis01.wch-rcc.com/ArcGIS/rest/services/Base/Buildings2/MapServer/0" &&
fieldInfo.fieldName == "TURNOVER_AREA") && (formattedAttributes[fieldInfo.fieldName] > "100-B/C" && formattedAttributes[fieldInfo.fieldName] < "100-K"))
{
break;
}else if (fieldInfo.visible && formattedAttributes[fieldInfo.fieldName] && formattedAttributes[fieldInfo.fieldName] != " ")
{
var fieldLabel:Label = new Label();
So, if I click on a feature from my Buildings2/MapServer/0 AND the field name = "TURNOVER_AREA" AND the value of TURNOVER_AREA is between "100-B/C and 100-K", then the TURNOVER_AREA field/value will NOT be added to the popup infowindow. The code in blue is what I added that does the evaluation. The code in red keeps the field/values from being added if the value is NULL or blank. Delete this if you want to show "empty" fields as well. The rest is existing code in the mxml. Should be able to modify this to suit your needs, R_ I see your service doesn't have attachments, so when you say that some counties don't have photos, does that mean that you have a field with photo names and/or urls in it, and some are blank/null? If so, the changes in red above will do exactly that. Well, almost, you will not see ANY fields (including photofield) on the infowindow if there isn't a value in it for that feature.
... View more
11-15-2012
10:52 AM
|
0
|
0
|
2269
|
|
POST
|
Andrew, This post will show you how/where to evaluate the attribute info so you could test for county range, etc. http://forums.arcgis.com/threads/67874-Popup-3.0-hide-field-if-value-null?highlight=popuprenderskin+config Just need to figure out if there is then a way to set the popupconfig.xml used from within the popuprenderskin. Not sure how the API works here. Is the popupconfig.xml "assigned" before the popuprenderskin is fired or after? If before, maybe you can modify the list of fields, if after, maybe actually assign the desired.xml. Not sure if it possible to set it, so hopefully someone will jump in with some info as to if this is possilbe, and give some ideas. R_
... View more
11-15-2012
09:14 AM
|
0
|
0
|
2269
|
|
POST
|
I cannot get both of my two defintionexpression clauses to function properly simultaneously. With the code below, only the second expression takes affect. <layer label="NC Surveyed Only" type="dynamic" visible="true" alpha="1.0"
url="http://gis.ncdcr.gov/ArcGIS/rest/services/NC_Surveyed_Only/MapServer">
<sublayer id="0" popupconfig="popups/PopUp_Surveyed_NoPhoto.xml" definitionexpression="County <> 'Brunswick' AND County <> 'Bertie'" />
<sublayer id="0" popupconfig="popups/PopUp_Surveyed_Photo.xml" definitionexpression="(County = 'Brunswick') OR (County = 'Bertie')" />
<!-- sublayer id="0" popupconfig="popups/PopUp_Surveyed_Photo.xml" /> -->
</layer> I suspect that both are taking affect, it is just that the second one for id="0" is overwritting the first one as only one can be assigned to id="0". I would suspect that to do this, you would have to link it to a custom popuprenderskin if it is possible. One would have to look into if/how you can set the popupconfig.xml being used in the popuprenderskin. If possible, then you could do an if/then statement to check for you criteria, and assign the proper xml. This is where I put the coding to make the popup behave differently for different layers clicked on. Though for mine, I have it add radio buttons IF I click on certain layers in the map so not sure about coding/access to the attribute data and ability to asign xml. R_
... View more
11-15-2012
08:32 AM
|
0
|
0
|
2269
|
|
POST
|
As far as the uniquevalsfromfield adding a blank I had this fixed at one point them made some more code changes to account for a possible empty string value being in the data and I broke it again. But I now have it fixed again. Please re-download the widget. This brings up a good point/question: What happens if I have the value "all" in my data? Will selecting "all" just query them, or everything in the list? R_
... View more
11-15-2012
08:15 AM
|
0
|
0
|
1785
|
|
POST
|
Rhett, I should have explained this one better. My statement notice my bolded text, search graphic not a popup.xml that you define in the main config.xml for a layer. I see. Guess I thought it was always the same popup when fired anywhere from the eSearchWidget. As far as the uniquevalsfromfield adding a blank I had this fixed at one point them made some more code changes to account for a possible empty string value being in the data and I broke it again. But I now have it fixed again. Please re-download the widget. Good to hear this as I was a little concerned that I was doing something wrong as I couldn't repeat the results on your test site, even though it was reporting the same version (thus another unmodified test app). And yes, it appears to be fixed now. Have noticed an issues still with getting the uniquevalues from field option. * Fixed bug where if more than one uniquevalsfromfield was used in an expression Only one would populate the dropdown. This appears to still be the case IF the layer with more than one is the first layer listed in the eSearchWidget.xml. It will populate one of the dropdowns only. Used to be I had to select a different layer/expression, then back and it would populate the "next" box, then had to do it again for each value that was using uniquevalsfromfield. Well, now when I navigate back to it, it will populate ALL of them. OR, if I set that layer as something other than the first layer, it will populate them all when I "choose" it from the dropdown. So, it appears as if it is not populating ALL of the uniquevalsfromfield dropdowns at once if the layer is loaded by default, but only if the layer is selected by the dropdown. R_
... View more
11-15-2012
08:13 AM
|
0
|
0
|
1785
|
|
POST
|
Got this one also trying to search, but, I copy/paste the link into a browser, or reload and it opens: SecurityError: Error #2048: Security sandbox violation: http://gis01.wch-rcc.com/final3/index.swf cannot load data from http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Louisville/LOJIC_PublicSafety_Louisville/MapServer/2?f=json.
at com.esri.ags.tasks::BaseTask/handleFaultEvent()
at mx.rpc::AsyncResponder/fault()
at mx.rpc::AsyncToken/http://www.adobe.com/2006/flex/mx/internal::applyFault()
at mx.rpc.events::FaultEvent/http://www.adobe.com/2006/flex/mx/internal::callTokenResponders()
at HTTPOperation/http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent()
at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()
at mx.rpc::Responder/fault()
at mx.rpc::AsyncRequest/fault()
at DirectHTTPMessageResponder/securityErrorHandler()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/redirectEvent()
attached is the fiddler2 log for all entries from the esri server during this load. R_
... View more
11-15-2012
07:53 AM
|
0
|
0
|
2011
|
|
POST
|
a couple thoughts. I have my popups set to not show the field if it is NULL or NoData. If you are displaying other info as well, you could modify it this way, that way it would not show blank photo fields and would only populate them if data exists in the field. Could copy the layer twice in ArcMap and put your two different expressions on each layer, group them and publish as a service. If you load as type=dynamic, then you can assign a different popup.xml for each sublayer. If you don't need the ability, you can disable the expand capability of the TOC so that it "looks" like one layer in the TOC with a single checkbox to turn on/off (don't know if you can disable the expand for a single layer). Could also load the layer twice with different name and "hide" one of them from the TOC. Of course, this method would not let you turn on/off the "hidden" layer without modifying the mxmls (something like if layer1 visible=false, then layer2 visible=false). Just some thoughts, R_
... View more
11-15-2012
07:43 AM
|
0
|
0
|
2269
|
|
POST
|
Did not have fiddler running, and can't get it to do it again (ie, the "random" part), but here is the error message that I get: SecurityError: Error #2048: Security sandbox violation: http://gis01.wch-rcc.com/otb/index.swf cannot load data from http://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/?f=json.
at com.esri.ags.tasks::BaseTask/handleFaultEvent()
at mx.rpc::AsyncResponder/fault()
at mx.rpc::AsyncToken/http://www.adobe.com/2006/flex/mx/internal::applyFault()
at mx.rpc.events::FaultEvent/http://www.adobe.com/2006/flex/mx/internal::callTokenResponders()
at HTTPOperation/http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent()
at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()
at mx.rpc::Responder/fault()
at mx.rpc::AsyncRequest/fault()
at DirectHTTPMessageResponder/securityErrorHandler()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/redirectEvent() However, I can copy/paste the MapServer URL and it opens. Or, reload the map, sometimes it errors, usually it opens. R_
... View more
11-15-2012
06:58 AM
|
0
|
0
|
2011
|
|
POST
|
I've been trying to figure this one out myself. If I set addarcgisbasemaps="true" I will randomly get the error message that it can't find the topo layer on map load. But, if I copy/paste the service URL as listed in the error message, it opens the REST page just fine. Can never get it to repeat, and seems just random. Solution for me is to not use ESRI basemaps. If this is one of your services, you may try to delete it, and re-create. Might even try re-creating with a different service name and see if it makes a difference. R_
... View more
11-14-2012
02:48 PM
|
0
|
0
|
2011
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 05-21-2026 08:53 AM | |
| 1 | 05-14-2026 04:28 PM | |
| 1 | 05-07-2026 02:10 PM | |
| 1 | 04-02-2026 09:50 AM | |
| 1 | 04-01-2026 01:21 PM |
| Online Status |
Online
|
| Date Last Visited |
Monday
|