AnsweredAssumed Answered

How to create an if statement within ArcGIS JS API with combo boxes

Question asked by geoffreywestgis on Oct 7, 2014

I am using the local government Public Information Center template   I would ideally like to create an if statement which listens for subcategories of request types.  However, my subcategories must be an array of items and not single items.

 

An example of this from the template found here would be;   Public Information Center

 

If I choose insect problem underneath the request service tab, then another combo box appears and populates with various types of insects. 

 

 

My start is here; 

dijit.byId('cbRequestType').on('change', Populaterequesttype { ... if (Populaterequesttype  == 'insect problem') bar = ants, roaches, spiders, termites;  ... }

Outcomes