|
POST
|
What I ended up doing was setting the Editor Widget _currentGraphic property equal to the graphics (results) or my featureLayer.selectFeatures query. featureLayer.selectFeatures(query, esri.layers.FeatureLayer.SELECTION_NEW, function (results) { ZoomToFeature(results) }); setGraphicsAttributes(result); function setGraphicsAttributes (graphic) { editorWidget._currentGraphic = graphic; }
... View more
01-23-2013
06:57 AM
|
0
|
0
|
412
|
|
POST
|
I am using the editorWidget to add new features, delete features, and update features. I am using the Attribute Inspector to display and edit the newly added features and selected features attributes. I recently added a function to my application which allows the user to search for an existing editable feature by a unique identifier (asset_id). I am using the .selectFeatures() method on the FeatureLayer to select and then zoom to a feature based on the asset_id. The attributes for the selected feature display within the attribute inspector with any associated domains and it appears that the fields are editable, but my application errors when a change is made within the attribute inspector. It appears that the attribute inspector is behaving like an info window and is not connected to the FeatureLayer for editing as I get an error which states. Unhandled exception at line 19, column 158500 in http://serverapi.arcgisonline.com/jsapi/arcgis/3.3/js/esri/dijit/editing/Editor-all.js 'this._currentGraphic.attributes' is null or not an object How can I connect the changes made via the attribute inspector in the above example back to the editor widget? Thanks, Mele
... View more
01-22-2013
07:40 AM
|
0
|
1
|
774
|
|
POST
|
We are using Visio 2007 to create XML Geodatabase Schemas. When importing the XML using the CASE Tools Schema Wizard in ArcCatalog 10 SP5, we get an error message that states: "Problem with Grid Sizes ..." for each feature class in the workspace being imported. The last time that I used the Schema Wizard to import the same XML digram about six months ago, I did not see this error. We now have had to manually set a Grid Value for Grid 1 for each Feature Class when importing which is a tedious work around. Has anyone enountered this error and found a way to fix it? Thanks, Mele
... View more
01-18-2013
10:26 AM
|
0
|
2
|
493
|
|
POST
|
We have ArcGIS Server 10.1 installed and are using the Web Adaptor. Our server is on our internal network and is using reverse-proxy to serve maps to the Internet. When a query is performed using a GET that has a Where clause such as Addr Like '%3%' http://MyServer/arcgis/rest/services/MyService/MapServer/1/query?where=Addr+Like+%27%253%25%27&f=pjson the query returns results, but if the Where clause is: Addr Like '%36%' http://MyServer/arcgis/rest/services/MyService/MapServer/1/query?where=Addr+Like+%27%2536%25%27&f=pjson A 500 Internal Server Error is produced. I suspect a filter setting in IIS is stopping the Query, but don't know where to look. Has anyone encountered this same issue? If so, how did you resolve it?
... View more
01-10-2013
01:36 PM
|
0
|
3
|
2891
|
|
POST
|
We have non feature linked water annotation and water mains with feature linked annotation. In order to transfer existing anno to feature linked annotation the user selects an existing annotation feature and a water main. The program then creates a new feature linked annotation feature where the selected non-feature linked annotation is placed. The program also assigns the Water Main OID of the selected water main to the feature linked annotation LinkedFeatureID. The feature linked annotation is forced to update by setting a field in the water main. In our case, we just updated the Owner field to its current value and then the feature linked annotation is forced to update. Finally the program deletes the non-feature linked annotation. Attached is the code that does the items described above. public static IFeatureClass FCmain_anno; - set to feature linked annotation feature class
public static IFeatureClass FCmain; - set to water main feature class
public static IFeatureSelection FMainSel; set to selected water main
public static ISelectionSet MainSelSet;
public static ISelectionSet Anno_SelSet;
public static IFeatureCursor FCur_main;
public static IFeatureCursor FCur_anno;
public static IFeature FMain;
public static IFeature F_anno;
public static IAnnotationFeature2 Anno_Feat;
FCmain_anno = FLmain_anno.FeatureClass;
FCmain = FLmain.FeatureClass;
//get main feature
IQueryFilter QF = null;
FMainSel = (IFeatureSelection)FLmain;
MainSelSet = FMainSel.SelectionSet;
MainSelSet.Search(QF, false, out Cur_Main);
FCur_main = (IFeatureCursor)Cur_Main;
FMain = FCur_main.NextFeature();
//get existing anno feature
F_annoSel = (IFeatureSelection)FL_anno;
Anno_SelSet = F_annoSel.SelectionSet;
Anno_SelSet.Search(QF, false, out Cur_anno);
FCur_anno = (IFeatureCursor)Cur_anno;
F_anno = FCur_anno.NextFeature();
Anno_Feat = (IAnnotationFeature2)F_anno;
//create new main anno feature
IFeature wmannoFeature = FCmain_anno.CreateFeature();
IAnnotationFeature2 FLannoFeat = (IAnnotationFeature2)wmannoFeature;
FLannoFeat.Annotation = Anno_Feat.Annotation;
UID edUID = new UIDClass();
edUID.Value = "{F8842F20-BB23-11D0-802B-0000F8037368}";
IEditor editor = (IEditor)m_application.FindExtensionByCLSID(edUID);
IEditLayers EditLayers = (IEditLayers)editor;
EditLayers.SetCurrentLayer(FLmain_anno, 0);
//assign OID to feature linked anno
int OIDFieldvalue = FMain.OID;
FLannoFeat.LinkedFeatureID = OIDFieldvalue;
//assign AnnoClassID
int annoclassid = 0;
FLannoFeat.AnnotationClassID = annoclassid;
//store feature
editor.StartOperation();
wmannoFeature.Store();
editor.StopOperation("Done");
////Get new feature linked anno feature and set symbolID
IQueryFilter pQF = new QueryFilterClass();
pQF.WhereClause = "FeatureID = " + OIDFieldvalue;
IFeatureCursor FLannoCursor = FCmain_anno.Update(pQF, false);
long symbolid = 0;
wmannoFeature = FLannoCursor.NextFeature();
wmannoFeature.set_Value((FCmain_anno.FindField("SymbolId")), symbolid);
editor.StartOperation();
FLannoCursor.UpdateFeature(wmannoFeature);
wmannoFeature.Store();
editor.StopOperation("IDs updated");
IQueryFilter mQF = new QueryFilterClass();
mQF.WhereClause = "OBJECTID = " + OIDFieldvalue;
IFeatureCursor mFCursor = FCmain.Update(mQF, false);
IFeature mF = mFCursor.NextFeature();
mF.set_Value(FCmain.FindField("Owner"), mF.get_Value(FCmain.FindField("Owner")));
editor.StartOperation();
mFCursor.UpdateFeature(mF);
editor.StopOperation("Main Updated");
//delete original anno
F_anno.Delete();
pMap.ClearSelection();
mxDoc.ActiveView.Refresh(); I hadn't look at this code for a while so I had to step through the code to jog my fading memory. I hope this makes sample makes some sense. Mele
... View more
11-07-2012
05:40 AM
|
0
|
0
|
863
|
|
POST
|
I contacted ESRI Support since posting this to the forum. They did not provide assistance for ISA/TMG configuration for ArcGIS Server 10.1 as they said it was out of scope for Support Services as it deals with non-ESRI products. They suggested I contact Microsoft or ESRI Professional services for help. I don't know that Microsoft will know how to configure ArcGIS Server, and I would like to avoid paying Technical Services for information ESRI provided for ArcGIS 10. I am not in the position to experiment with TMG settings as it is out of my department's control, so I hope to get some more detailed instructions to give to our IT security team. Mele
... View more
11-06-2012
11:23 AM
|
0
|
0
|
843
|
|
POST
|
Johannes, I was able to get something to work, I am reviewing my code so I can refresh my mind as to what it actually does. I will post some code and an explanation to this forum once I figure out what I did. Mele
... View more
11-05-2012
06:18 AM
|
0
|
0
|
863
|
|
POST
|
We have implemented the esri.toolbars.Navigation in an application and I would like to make it work so that when someone clicks once on the map, the map either zooms in or zooms out depending on the tool selection using the click point as center. I would also like to have rubber band zoom enabled when using the Zoom in tool. Has anyone implemented something like this? Thanks for your assistance. Mele
... View more
10-22-2012
03:46 PM
|
0
|
2
|
1594
|
|
POST
|
Thanks for your response. I am considering using the web adaptor as you suggested. Do I simply need to provide the internal machine name as Server.Domain:Port to our ISA Server Administrator using the port number used by the web adaptor? Mele
... View more
10-22-2012
03:00 PM
|
0
|
0
|
843
|
|
POST
|
I am not an IT security staff member but rather a GIS Analyst and I am trying to understand how to tell our IT Security team what is needed to make the ArcGIS 10.1 Server installation that will be housed on our internal network accessible to our DMZ and the Internet. We have an existing reverse proxy that is using Microsoft Forefront Threat Management gateway. We have successfully configured ArcGIS Server 10 to use our reverse proxy following the instructions provided in this document for a Microsoft ISA Server. http://support.esri.com/en/knowledgebase/techarticles/detail/32634 However, as the architecture has changed in ArcGIS Server the instructions do not apply to 10.1. As I understand it, we are trying to "intergrate with an existing reverse proxy" as shown below, but the instructions are only for Apache. http://resources.arcgis.com/en/help/main/10.1/index.html#//01550000042s000000 Do I simply need to provide the internal machines name and port number to out Security Team? Is there any reason to use the Web Adaptor in this scenario? Thanks for any assistance, Mele
... View more
10-21-2012
04:46 PM
|
0
|
5
|
1383
|
|
POST
|
Here is how I solved my problem. Probably could use a little clean up, but it is working on my application function featureCreate() { for (var x = 0; x < featureLayers.length; x++) { var featureLayer = COSMap.prototype.featureLayers drawSelectedFeature(featureLayer); drawNewFeature(featureLayer); } }; //draws newly added Feature function drawNewFeature(layer) { dojo.connect(layer, "onEditsComplete", function (addResults, updateResults, deleteResults) { dojo.forEach(addResults, function (addResult) { var query = new esri.tasks.Query(); query.where = "OBJECTID =" + addResult.objectId; var featureSelectionSymbol = new esri.symbol.SimpleMarkerSymbol(esri.symbol.SimpleMarkerSymbol.STYLE_SQUARE, 20, new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_SOLID, new dojo.Color([255, 0, 0]), 2), new dojo.Color([0, 255, 255, 0.25])); layer.setSelectionSymbol(featureSelectionSymbol); layer.selectFeatures(query, esri.layers.FeatureLayer.SELECTION_NEW); }); }); }; //Draws Currently selected Feature function drawSelectedFeature(layer) { dojo.connect(layer, "onClick", function (evt) { var featureSelectionSymbol = new esri.symbol.SimpleMarkerSymbol(esri.symbol.SimpleMarkerSymbol.STYLE_SQUARE, 20, new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_SOLID, new dojo.Color([255, 0, 0]), 2), new dojo.Color([0, 255, 255, 0.25])); layer.setSelectionSymbol(featureSelectionSymbol); var query = new esri.tasks.Query(); query.geometry = evt.mapPoint; query.returnGeometry = true; query.maxAllowableOffset = 500; layer.selectFeatures(query, esri.layers.FeatureLayer.SELECTION_NEW); }); }
... View more
10-18-2012
09:07 AM
|
0
|
0
|
684
|
|
POST
|
Here is what I ended up doing. var layers = dojo.map(results, function (result) { var layer = result.layer; var fields = layer.fields; var fieldinfo = []; for (var n = 0; n < fields.length; n++) { var field = fields ; if (field.name == 'Asset_ID') { var obj = { fieldName: field.name, isEditable: false } } else { var obj = { fieldName: field.name, isEditable: true } } fieldinfo.push(obj); } return { 'featureLayer': layer, 'fieldInfos': fieldinfo } }); var attInsp = new esri.dijit.AttributeInspector({ layerInfos: layers }, 'attr');
... View more
10-18-2012
09:03 AM
|
0
|
0
|
620
|
|
POST
|
We have an application which allows users to edit Feature Classes in SDE via a Feauture Server. We have a uniqure identifier field called "Asset_ID" in ten feature layers that will be populated with a unique number each time a feature is added using code similar to that below: //Added to update asset_id in feature before editing function beforeEdit(layer) { dojo.connect(layer, "onBeforeApplyEdits", function (adds, updates, deletes) { dojo.forEach(adds, function (add) { add.attributes.Asset_ID = 1234; }); }); } I would like the Asset_ID field to be read-only to the user so I tried to set the Read Only property for Asset_ID in the MXD when publishing the feature service, but then my code does not update the field, which makes sense so I have to set the read-only property to "no" for the field in the MXD. I then tried to change fieldInfos property for Asset_ID to 'isEditable':true for the Feature Layers used by the Attribute Inspector, but the problem I found was that I had to specify each field in the fieldInfos collection that I would like to show in the Attribute Inspector, but our feature classes have different attributes so I feeld it would be cumbersome to handle ten feature layers in this manner. How can I update the Asset_ID field while showing it as Ready-Only in the Attribute Inpsectore and aslo prevent the user from changing its value. Thanks for any assistance. Mele
... View more
10-15-2012
01:11 PM
|
0
|
1
|
1380
|
|
POST
|
Are there an Events that I can use to get the selected features being used by the attribute inspector and when features are added to the map? I am using the editor widget in combination with the Attribute Inspector. I have also created a Template picker and used that with the editor widget. In my application, I am editing points, lines, and polygons from a Feature Server using the On Demand Mode. I have seen examples that show selected features using the On Selection mode, but was not pleased with having to add both the map server and the featureServer layers so I am trying to find another way. I would like to be able to start a function that draws a graphic for the point features when they are selected and displayed in the attribute inspector, as well as when the features are first completed. What I am currently doing is using the "onClick" event and then I get the colleciton of feature layers in the map, loop through each to find those that have a geomtryType of "esriGeometryPoint", and then using the getSelectedFeatures() method to retrieve any features that may be selected. This process does not always seem to work that well as the selected features are not always displayed. Thanks for any assitance, Mele
... View more
09-26-2012
01:54 PM
|
0
|
1
|
1077
|
|
POST
|
Kelly, Thanks for your code. This works great and is what I was looking for. Mele
... View more
09-19-2012
02:28 PM
|
0
|
0
|
1019
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 10-20-2025 05:21 AM | |
| 1 | 03-13-2015 04:39 PM | |
| 1 | 09-18-2025 08:33 AM | |
| 1 | 05-12-2025 03:17 PM | |
| 1 | 08-15-2025 03:36 PM |
| Online Status |
Offline
|
| Date Last Visited |
3 weeks ago
|