Hoppa till huvudinnehållet

Customize Alert/error pop-up?

Kommentarer

6 kommentarer

  • Permanently deleted user
    This doesn't give me any insight on HOW it would successfully be implemented, or where to insert text for the custom error message.

     

    Are there any xaml examples for or related to this?
    0
  • Dan Giersz
    Looking at the documentation Nico linked to, I would put your SetMapExtent task in the Try section and then an Alert box with your custom text in the Catch section.  Although your error is probably due to an empty featureset from your query.

     

    Flow Decisions may be better suited for checking the query results and/or input values.
    0
  • Permanently deleted user
    Thanks, Dan. I'll give that a shot and see what it yields.

     

    I tried it with checking the query, but it did not do anything and the same message was returned instead of a custom alert. Would I need to set exceptions?
    0
  • Dan Giersz
    That error in the Alert box you posted is for the SetMapExtent task, not the query.  If you are using the query results to set the map extent, your query probably is not returning any results.  Not returning results is not the same as throwing an error.
    0
  • Permanently deleted user
    True. I was just using that as an example. I would like to be able to customize alerts for both no results/no features found and incorrect input. I didn't think of the problem lying in SetMapExtent. Thanks for that insight!
    0

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