We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

filterbar autocomplete?

Is there any way to make the filterbar have autocomplete capabilities?

4 Replies

Administrator August 22, 2003 12:59 PM UTC

To get the autocomplete using the standard GridFilterBar, try this. In the sample we ship (), remove the line in SetTableIntoGridAndWireFilterBar that reads theFilterBar.WireGrid(this.gridDataBoundGrid1); and replace it with this code. GridStyleInfo style = new GridStyleInfo(); style.ModifyStyle(this.gridDataBoundGrid1.BaseStylesMap["Header"].StyleInfo, StyleModifyType.Copy); style.CellType = "ComboBox"; style.ExclusiveChoiceList = true; style.BaseStyle = "Standard"; style.Font.Bold = false; style.BackColor = this.gridDataBoundGrid1.TableStyle.BackColor; style.Borders.Bottom = new GridBorder(GridBorderStyle.Dashed); style.DropDownStyle = GridDropDownStyle.AutoComplete; theFilterBar.WireGrid(this.gridDataBoundGrid1, style); This adds the DropDownStyle = AutoComplete setting to the default combobox.

SA scot adams August 22, 2003 03:01 PM UTC

can't thank you enough for all the speedy help... you're awesome

DU duyu August 29, 2003 12:20 PM UTC

Is there any way to make the filterbar use 'LIKE a*' to filter the data, instead of using the '=a' currently?

Administrator August 29, 2003 12:48 PM UTC

If you want to see the items in the grid dynamically filter as you type into the filter cell, then here is a little sample that does this. It uses a derived GridFilterBar class to implement this functionality.
Live Chat Icon For mobile
Up arrow icon