|
POST
|
I have an application where a user can add graphics including text to the map. I also have a geocoding tool where the user can locate an address and a marker symbol will display along with the address as a text label. The issue is that the text will not print in my print layout that I have configured. If the user adds in text to the map, they can change the color, size and angle. However, when pringing out the map using the print widget, none these settings carry over to the print layout. By default, the text shows up in black. I am currently using the ArcGIS JavaScript 3.5 API. Are there any solutions to these issues? Please refer to the screenshots: Text from Geocoding Tool 1. Application with Point (Address Point) and Text (Address Label): [ATTACH=CONFIG]33620[/ATTACH] 2. Application Printed Out using Print Widget (notice missing Address Labels): [ATTACH=CONFIG]33621[/ATTACH] Adding Text 1. Added Text as University, Red, 20pt, Normal, Align Start, Text Angle 45 within the map [ATTACH=CONFIG]33622[/ATTACH] 2. When generating a Print Out (notice the text is in black) [ATTACH=CONFIG]33623[/ATTACH]
... View more
05-06-2014
07:08 AM
|
0
|
5
|
2515
|
|
POST
|
That was my mistake. I sent the wrong script. I've attached the correct one. How can I use this tool for the Javascript application? For instance, I want to be able to select records and just export those records to a .csv file. I need this to work against a feature service. How do I use this tool with a feature service? Is this more of an ArcGIS Desktop tool?
... View more
01-07-2014
11:10 AM
|
0
|
0
|
1930
|
|
POST
|
Thanks for the script. I just want to clarify. . this will work within a javascript application using a feature layer correct? You mentioned feature class, which tells me that this will work for a desktop application? I will have selection tools that will select the feature layer within the application. Are you saying I can create a geoprocessing service that I can run to export the selected records within the application? If so, I will try this out when I return to the office next week. I am out of the office, so I cannot test until next week.
... View more
12-23-2013
03:47 AM
|
0
|
0
|
1930
|
|
POST
|
I am interested in adding in functionality that allows the user to select records from a feature layer and then have them export them to a .csv file. I checked the JS API and samples and did not see this functionality. I do not want a shapefile or feature class exported, just a table. Users who will be using this will not have an ArcGIS Desktop install. Has anyone been able to get something like this to work? Would be very interested in your ideas. Thanks.
... View more
12-20-2013
06:52 AM
|
0
|
14
|
7954
|
|
POST
|
Here's a sample that shows how to do that with a gif and here's one with text. That isn't quite what I am looking for. This animated .gif shows up when the application loads and when the user performs a zoom or pan on the map. All I need is to have a screen come up one time each time the application is opened in the browser.
... View more
12-12-2013
07:56 AM
|
0
|
0
|
1304
|
|
POST
|
to accomplish this I have a [HTML]<div id="wait" class="esriSimpleSlider"> <img src="ajax-loader.gif"> </div>[/HTML] that shows in the center of the screen. Then using the map.on load event (which fires when the application has finished loading) i hide it. loading = dom.byId("wait");
map.on("load", function() {
esri.hide(loading);
//other stuff
}); There are probably more elegant ways of doing this, but I hope this helps. Thanks. Will this only appear when the application is first loaded? I don't want it to show up each time a user makes a zoom or pan on the map.
... View more
12-12-2013
07:55 AM
|
0
|
0
|
1304
|
|
POST
|
I am interested in building a splash screen that tells the user that the application is loading. When the application is finished loading, I am wanting the screen to disappear. Has anyone put something like this together? I am looking at something similar to what the Silverlight Viewer displays. Any assistance will greatly be appreciated.
... View more
12-12-2013
04:41 AM
|
0
|
6
|
2081
|
|
POST
|
I have a measurement widget within my application. When measuring, the default is set as Miles. Can I change the default units to Feet? Also, the default for measuring areas is set to Acres. . I need to default to Sq Feet. Thanks.
... View more
10-29-2013
01:03 PM
|
0
|
3
|
3674
|
|
POST
|
Any new features expected such as drawing and zoom tools? Kind of surprised drawing and navigation tools haven't been introduced, especially since users are using these applications out in the field.
... View more
10-22-2013
12:37 PM
|
0
|
0
|
965
|
|
POST
|
I was just thinking, could I have a button that activates the dojo.connect and a button that disconnects the dojo.connect? Using this: // EDITING - CONNECT MAP WITH EDITOR TOOLBAR dojo.connect(map, "onLoad", createEditToolbar); // EDITING - CONNECT MAP WITH DELETE FEATURE TOOL dojo.connect(map, "onLayersAddResult", editingDeleteFeature);
... View more
10-09-2013
07:30 PM
|
0
|
0
|
752
|
|
POST
|
Hi Ian, what you can do is assign the event listener to some variable and use dojo.disconnect method to remove the eventlistener on the button click. here's an example: //global variable var PSFLEventListener; var NewEventListener; //use the below to attach the event listener PSFLEventListener = dojo.connect(plantingsitesFL, "onClick", function(evt) { dojo.stopEvent(evt); activateEditToolbar(evt.graphic); activeFeatureLayer = plantingsitesFL; }); //use the below to disconnect on button click and attach the new using the same method. function button_onclick(){ dojo.disconnect(PSFLEventListener); NewEventListener = dojo.connect(publictreeinventoryFL, "onClick", function(evt) { dojo.stopEvent(evt); activateEditToolbar(evt.graphic); activeFeatureLayer = publictreeinventoryFL; }); } Hope this helps. Regards, Manish Thanks for the feedback how would that work with the code block below? The two tools are identify by the comments.
// EDITING - CONNECT MAP WITH EDITOR TOOLBAR
dojo.connect(map, "onLoad", createEditToolbar);
// EDITING - CONNECT MAP WITH DELETE FEATURE TOOL
dojo.connect(map, "onLayersAddResult", editingDeleteFeature);
// *****************************************************************************
// * EDIT FEATURES - MOVE, EDIT VERTICES, SCALE, ROTATE, OPTIONS *
// *****************************************************************************
function createEditToolbar() {
var activeFeatureLayer = null;
var landuseLayerFL = map.getLayer("landuseLayer");
var militaryareasFL = map.getLayer("militaryareas");
editModifyFeaturesTools = new esri.toolbars.Edit(map);
// ACTIVATE TOOLBAR WHEN CLICKING ON LAND USE
dojo.connect(landuseLayerFL, "onClick", function(evt) {
dojo.stopEvent(evt);
activateEditToolbar(evt.graphic);
activeFeatureLayer = landuseLayerFL;
});
// ACTIVATE TOOLBAR WHEN CLICKING ON MILITARY SITES
dojo.connect(militaryareasFL, "onClick", function(evt) {
dojo.stopEvent(evt);
activateEditToolbar(evt.graphic);
activeFeatureLayer = militaryareasFL;
});
// DEACTIVATE TOOLBAR
dojo.connect(map,"onClick", function(evt){
editModifyFeaturesTools.deactivate();
});
// POST EDITS AFTER TOOL IS DEACTIVATED
dojo.connect(editModifyFeaturesTools, "onDeactivate", function(editTool,graphic) {
activeFeatureLayer.applyEdits(null, [graphic], null);
alert("Feature successfully updated.");
});
}
// ACTIVATE TOOLBAR EDITING
function activateEditToolbar(graphic) {
var editTool = 0;
if (dijit.byId("tool_move").checked) {
editTool = editTool | esri.toolbars.Edit.MOVE;
}
if (dijit.byId("tool_vertices").checked) {
editTool = editTool | esri.toolbars.Edit.EDIT_VERTICES;
}
if (dijit.byId("tool_scale").checked) {
editTool = editTool | esri.toolbars.Edit.SCALE;
}
if (dijit.byId("tool_rotate").checked) {
editTool = editTool | esri.toolbars.Edit.ROTATE;
}
// SPECIFY TOOLBAR OPTIONS
var options = {
allowAddVertices: dijit.byId("vtx_ca").checked,
allowDeleteVertices: dijit.byId("vtx_cd").checked,
uniformScaling: dijit.byId("uniform_scaling").checked
};
editModifyFeaturesTools.activate(editTool, graphic, options);
}
// *****************************************************************************
// * DELETE FEATURES *
// *****************************************************************************
function editingDeleteFeature(results) {
var layers = dojo.map(results, function (result) {
return result.layer;
});
// DELETE FEATURE USING ONCLICK
dojo.forEach(layers, function (deleteFeatureslLayer) {
dojo.connect(deleteFeatureslLayer, "onClick", function (evt) {
dojo.stopEvent(evt);
// DELETE FEATURE IS DELETE BUTTON IS CHECKED (ACTIVE)
if (dijit.byId("tool_delete").checked) {
deleteFeatureslLayer.applyEdits(null, null, [evt.graphic], function () {
operation = new esri.dijit.editing.Delete({
featureLayer: deleteFeatureslLayer,
deletedGraphics: [evt.graphic]
});
// ALERT WHEN FEATURE IS DELETED
alert("Feature deleted.")
});
}
});
});
}
... View more
10-09-2013
07:08 PM
|
0
|
0
|
752
|
|
POST
|
I have two toolsets. . one is used to modify features (move, rotate, scale, edit vertices) on the map and the other is used to delete features on the map. The problem is that my delete tool will not work with the modify features toolset. If the move feature button is checked from the modify features toolset, then I can delete a feature, but I want these tools to work separately. My question is, can I disable a tool using a button? I have attached a code sample. Any feedback will greatly be appreciated.
... View more
10-09-2013
04:20 PM
|
0
|
3
|
1417
|
|
POST
|
Attached is a sample application that shows a modular structure. The small sample contains navigation tools, drawing, find, geocoding, and a template picker. NOTE** When you open this application it will be broken. The application is broken because I replaced my map services and references with <machinename>. You will need to use your own map services and adjust the code accordingly. When you are able to add in your own references and map services, the application should work.
... View more
10-09-2013
12:02 PM
|
0
|
0
|
1684
|
|
POST
|
I haven't forgotten about you guys. I will need to strip some stuff out of the application before attaching it. The application will include drawing, geocoding, editing, printing, and find tasks. Give me until tomorrow and I will attach a sample application.
... View more
10-08-2013
11:16 AM
|
0
|
0
|
1684
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 04-01-2022 05:53 AM | |
| 1 | 09-18-2018 06:17 AM | |
| 1 | 06-19-2018 10:31 AM | |
| 1 | 05-15-2018 10:42 AM | |
| 1 | 10-14-2015 03:59 PM |
| Online Status |
Offline
|
| Date Last Visited |
06-10-2025
07:13 AM
|