Skip to main content

How to turn off Export to Shapefile

Comments

6 comments

  • Angeleta Wilson

    Did you ever get a response to this? I am having the same issue and the GeoCortex help system has nothing related to it. We definitely do not want just anyone to be able to export our data, but it seems to be there by default now when features are identified.

    0
  • Permanently deleted user

    Ryan,

    We had one of your support look into this exact same issue. His response was:

    At this time, there is no option within Essentials Manager to remove this functionality, however, the following modifications can be made to the viewer.defaults.xml file, which will completely remove the option:

    Note:  Always create a backup of the configuration file before making modifications to it.

    LayerList Module

     

    LayerListSelectionActionsMenu - remove <Item Text="Export to Shapefile" Command="ExtractFeatureSet" />

    Results Module

     

    ResultsListActions menu - remove <Item Text="Export to Shapefile" ToolTip="Export to Shapefile" Command="ExtractFeatureSetCollection" Module="Extract"/>

     

    ResultsTableActions menu - remove <Item Text="Export to Shapefile" ToolTip="Export to Shapefile" Command="ExtractFeatureSet" Module="Extract"/>

    Selection Module

     

    SelectionActions menu - remove <Item Text="Export to Shapefile" ToolTip="Export to Shapefile" Command="ExtractFeatureSetCollection"/>

     

    SelectionLayerMenu - <Item Text="Export to Shapefile" Command="ExtractFeatureSet" />

     

    HistoricalResultsRootMenu - remove <Item Text="Export to Shapefile" ToolTip="Export to Shapefile" Command="ExtractFeatureSetCollection"/>

     

    HistoricalResultsLayerMenu - remove <Item Text="Export to Shapefile" Command="ExtractFeatureSet" />

    We've made the suggested changes to our Viewer.Default.xml file, then created a new Silverlight v2.2 viewer, but unfortunately, the "Export to Shapefile" was not disabled completely and still appears in the results pane. With one feature set, it states that "The extract operation could not complete successfully. Please contact your system administrator for assistance. But with another feature, the "Export to Shapefile" works as stated.

    Could there be caching issues? And if you remove the "Extract" module completely, would you still be able to run a workflow to extract data? When you make changes to your Viewer.Defaults.xml that file contains alot more functionality compared to the viewer.xml under the site. Does the viewer.xml still reference the Viewer.Defaults.xml file indirectly after the site is created?

    Walter

     

    0
  • Ryan Cooney

    Hi Walter,

    The manual changes to Viewer.Defaults.xml will remove the individual menu items. If they are still showing up in your viewer you will want to confirm that the viewer is actually loading your changes. The best way to do this is to use Fiddler to observe the web traffic. You will be able to see the Viewer.Defaults.xml get downloaded and ensure that your changes are in there. This might be a caching issue, but more commonly it is the wrong Viewer.Defaults.xml that was modified. If you are using Manager to create your viewers the Viewer.Defaults.xml that is used is located inside the .vte file (for example: C:\Program Files (x86)\Latitude Geographics\Geocortex Essentials\<INSTANCE>\REST Elements\Sites\Templates\Geocortex.Essentials.SilverlightViewer.Template.2.X.vte\VirtualDirectory\Viewer.Defaults.xml). You can use a tool like 7-Zip to edit to contents of a .vte file.

     

    When you remove the Extract module it removes the following command implementations:

    • ExtractGraphicsLayerById
    • ExtractGraphicsLayerGeometryById
    • ExtractFeatureSet
    • ExtractFeatureSetCollection
    • ExtractFeatureSetCollectionById
    • ExtractEsriFeatureSet

    These commands still exist but with their implementations removed they will not be able to run, so any menu items and toolbar buttons that reference them will appear disabled.

     

    The error you are getting when performing an extract with a particular feature set is likley something else entirely. Have a look in the logs of the REST application. An issue like this related to field name lengths was fixed in 4.1.1.

    --Ryan

    0
  • Permanently deleted user

    Ryan,

    Your suggestions worked like a charm. Thank you. The whole time we were editing the wrong file...!

    Your steps are pertinent when only a new viewer is created. But for existing ones, that "Export to Shapefile" still exists.

    Walter

    0
  • Permanently deleted user
    Hello! It's been a few years since this topic was opened but I have a follow-up question.

     

    For those of us with the HTML5 viewer, has anything changed? Besides simply disabling shapefile exports altogether, can we disable this function for certain layers?

     

    Thanks,

     

    Warren
    0
  • Permanently deleted user
    I am also interested in disabling shpefile, xlsx & csv exports for certain layers based on permissions.
    0

Please sign in to leave a comment.