AnsweredAssumed Answered

Search Widget set searchExtent

Question asked by jmitz on May 7, 2015
Latest reply on Sep 23, 2015 by rscheitlin

I would like to set the searchExtent for the default Locator  for the search widget, but I don't see an obvious way to do that.


I have successfully limited the search using the following code:


var searchExtent = new Extent({
     xmin: -91.5,
     ymin: 37,
     xmax: -87.5,
     ymax: 42.5,
     spatialReference: {
          wkid: 4326

var search = new Search({map: map}, "searchDiv");

search.sources[0].searchExtent = searchExtent;


Am I missing something?

Has anyone seen a better way to do this?