Hoppa till huvudinnehållet

how to use AddMapService command

Kommentarer

6 kommentarer

  • Permanently deleted user
    Anyone?

     

    I've found the constructor in the API, so would look for a Parameter for the AddMapService Command equivalent to 

     

    new MapService(url?: string): MapService
    0
  • Permanently deleted user
    Hi Maria, 

     

    If you check the documentation for the command (https://docs.geocortex.com/essentials/gvh/latest/commands-help/#/commands/Layer List/AddMapService) , you'll find that the parameter it needs is a Geocortex.Essentials.Client.MapService object.  Unfortunately I don't think you'll be able to use this command in a workflow.  Even if you're able to successfully create the MapService object, it won't be serializable, meaning you would get errors when you try to use it in client-side activities like RunExternalCommand.

     

    If you know ahead of time the layers that could need to be added to the map, you could put them in a layer catalog, and add a reference to the catalog on the site.  Adding layers from a layer catalog is definitely doable in a workflow; use the command "AppendCatalogLayers" with the string parameter catalogname.mapserviceid.layername

     

    You might also want to post on the Ideas section (https://support.geocortex.com/GSCIdeas?c=09a6000000008RsAAI&filter=1&categ=all&sub-nav=ideas&main-nav=essentials&page=1) and request that we provide a command or workflow activity that adds a layer to the map and only requires the url as a parameter.

     

    Hope that helps,

     

    Amanda
    0
  • Permanently deleted user
    I had the same need to add a result map service from GPservices to the viewer. It would be great to be able to do it through workflow. I have created an idea here (https://support.geocortex.com/essentialsGSCIdeasDetail?c=09a6000000008RsAAI&id=087f2000000fxX6AAI&categ=all&sub-nav=ideas&main-nav=essentials) , please vote up.
    0
  • Permanently deleted user
    Hello,

     

    i can not add a layer using the "AppendCatalogLayers" command with the string parameter catalogname.mapserviceid.layername when the layer name contains dots or commas. Is any chance to add those layers from Layer Catalog in WorkFlow. 

     

    Thank you,

     

    Marek
    0
  • Permanently deleted user

    Hi Malek,

     

    This is a bug. Special characters can't be part of a layer name when using "AddCatalogLayer" or "AppendCatalogLayers" in a workflow. I will add your name as a stakeholder on this.

     

    Thanks,

    Marion.

     

     
    0
  • Erik Engstrom
    Hi Marion, I'd like to be added as a stakeholder. 
    0

Du måste logga in om du vill lämna en kommentar.