We did this by using a combination of checkbox lists and input elements.
We had a use case where we had to provide a filter by price option to the user, the prices were varied and differed based on the product category.
As the user types the desired price, if it matches any of the items in the list the item gets checked.
If not a new checkbox is added with the users' entered price amount (store it as a cookie and show that custom checkbox when he revisits the page).
Users can select the checkboxes manually too,ignoring the textfield.
download bmml source – Wireframes created with Balsamiq Mockups
- it goes without saying that validation is foremost
- sometimes the user may not need a particular price range, but that may get inadvertently selected and filtered