Lee, There is not a code gallery entry for this as it is so specific to my data and site.That being said adding the radio button is pretty trivial. 1. add the radio button mxml code to the widget. I added it above the mx:Text with id=txtLabelText<mx:HBox width="100%" horizontalAlign="center" horizontalGap="10">
<mx:RadioButtonGroup id="radiogroup1" itemClick="changeOpt(event)"/>
<mx:RadioButton label="PPIN" groupName="radiogroup1" selected="true" id="idPPIN" styleName="WidgetText" />
<mx:RadioButton label="Parcel" groupName="radiogroup1" id="idParcel" styleName="WidgetText" />
<mx:RadioButton label="Owner" groupName="radiogroup1" id="idOwner" styleName="WidgetText" />
<mx:RadioButton label="Address" groupName="radiogroup1" id="idAddress" styleName="WidgetText" />
</mx:HBox>
2. Add the changeOpt functionprivate function changeOpt(event:ItemClickEvent):void{
switch(event.label.toLowerCase()){
case "ppin": {
txtLabelText.text = "Search Parcels by PPIN (Parcel ID Number) i.e. 1234"
queryExpr = "PPIN = '[value]'"
break;
}
case "parcel":{
txtLabelText.text = "Search Parcels by Parcel Number i.e. 1706140002014000"
queryExpr = "Parcel_Number = '[value]'"
break;
}
case "owner":{
txtLabelText.text = "Search Parcels by Owner Name i.e. Smith John (Last First)"
queryExpr = "NAME LIKE '%[value]%'"
break;
}
case "address":{
txtLabelText.text = "Search Parcels by Address i.e. 244 Cherokee TR"
queryExpr = "STREET_ADDRESS LIKE '%[value]%'"
break;
}
}
}
3. In the queryFeaturesText function replacequeryExpr = configSearchText.expr;
withif(queryExpr){
}else{
queryExpr = configSearchText.expr;
}
That should be it.