!57 UIComboDataGridView使用过滤功能时,字符串中包含 * ,需要加上'[]'进行转义
Merge pull request !57 from Schr0dingerCat/master
This commit is contained in:
commit
4aa6fd8911
@ -1,4 +1,4 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Data;
|
using System.Data;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
@ -365,7 +365,7 @@ namespace Sunny.UI
|
|||||||
filter = string.Join(" or ", strings);
|
filter = string.Join(" or ", strings);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
filter = filter.Replace("*", "[*]");
|
||||||
if (dataGridView.DataSource is DataTable table)
|
if (dataGridView.DataSource is DataTable table)
|
||||||
{
|
{
|
||||||
table.DefaultView.RowFilter = filter;
|
table.DefaultView.RowFilter = filter;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user