Hi anandhienator,
The logic itself is there in the script only, In that what ever the values you are taking, take those values in the arraylist so that while comparing take the values from arraylist.
before that do like this, drag the another copy of drop down list box and run the application. the copy of dropdown list box will show your selected item. that the value is saving in the combobox memory.
So compare the combobox value with the arraylist elements you can get the result.
Hope this will help you..
B.Shiva Prasad
InfoPath Dev,
http://www.ggktech.com
India