Query layer and display only queried results - Graphics or Feature Layer?

3897
2
05-14-2015 10:43 AM
JesseHopkins
New Contributor III

Hello,

I have a query widget that allows the user to pick a date range that a crime has occurred on, and query further on the crime's category (Stealing, Arson, etc.). When the query is ran, I would like to display only the results that meet that specific query as opposed to displaying all the crime points within that layer.  Is this a case where I would use a feature layer or graphics layer? Also, would I be able to keep the same picture marker symbol native to the layer in the MXD? I’m limited/stuck at Flex API 2.5. (working on a JS site now).  I've seen a few examples, but nothing that works with a query and/or keeps the symbology in tact.

Thanks!

0 Kudos
2 Replies
RobertScheitlin__GISP
MVP Emeritus

Jesse,

   I am confused.

When the query is ran, I would like to display only the results that meet that specific query as opposed to displaying all the crime points within that layer.

that is exactly what the query widget does my default.

0 Kudos
JesseHopkins
New Contributor III

Robert,

I was having a lot of problems working with the default query widget, but now I am more than likely using something out of date.  It's been a challenge dealing with someone else's mess! This widget is a customized version of a "Date Search" widget I found (I believe it was yours), The way it's set up now, the on-map results are shown with a push pin (or highlighted) - see images. I'm guessing I should incorporate what I have now back in the query widget?  Thanks.

PoliceCrime2.JPG

PoliceCrime.JPG

0 Kudos