Sign In| Join
Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Nov 09, 2012 05:06 PM by Mojorz
Member
3 Points
22 Posts
Nov 07, 2012 12:21 PM|LINK
string[] word = txt_search.Text.Split(' '); foreach (string str in word) { SqlConnection connection = Connection.GetDBConnection(); connection.Close(); select statement like str
cmd.Parameters.AddWithValue("@tag", str);
da.Fill(ds);
GridView1.DataSource = ds; GridView1.DataBind(); }
Any ideas ?
Star
8376 Points
1573 Posts
Nov 07, 2012 12:29 PM|LINK
Please post more complete code. We need to see what is in the foreach loop.
All-Star
31511 Points
6431 Posts
Nov 07, 2012 11:58 PM|LINK
Gridview dont have multiple selection. Gridview has selectedindex and selectedvalue property to determine which row you select.
16006 Points
1728 Posts
Microsoft
Nov 09, 2012 05:21 AM|LINK
Search records in GridView and highlight results:
http://www.aspdotnet-suresh.com/2011/12/search-records-in-gridview-and.html
Gridview Search word with highlight:
http://www.dotnetspark.com/kb/1971-gridview-search-word-with-high-light-using.aspx
ASP.NET GridView with search option
http://www.codeproject.com/Articles/43018/ASP-NET-GridView-with-search-option-SearchableGrid
Nov 09, 2012 05:06 PM|LINK
Thanks this links were a great help .
Thanks for your time .
Mojorz
Member
3 Points
22 Posts
Select all rows from gridview where column contain any words of a string
Nov 07, 2012 12:21 PM|LINK
string[] word = txt_search.Text.Split(' '); foreach (string str in word) { SqlConnection connection = Connection.GetDBConnection(); connection.Close(); select statement like strcmd.Parameters.AddWithValue("@tag", str);RichardY
Star
8376 Points
1573 Posts
Re: Select all rows from gridview where column contain any words of a string
Nov 07, 2012 12:29 PM|LINK
Please post more complete code. We need to see what is in the foreach loop.
oned_gk
All-Star
31511 Points
6431 Posts
Re: Select all rows from gridview where column contain any words of a string
Nov 07, 2012 11:58 PM|LINK
Gridview dont have multiple selection. Gridview has selectedindex and selectedvalue property to determine which row you select.
Frank Jiang ...
All-Star
16006 Points
1728 Posts
Microsoft
Re: Select all rows from gridview where column contain any words of a string
Nov 09, 2012 05:21 AM|LINK
Search records in GridView and highlight results:
http://www.aspdotnet-suresh.com/2011/12/search-records-in-gridview-and.html
Gridview Search word with highlight:
http://www.dotnetspark.com/kb/1971-gridview-search-word-with-high-light-using.aspx
ASP.NET GridView with search option
http://www.codeproject.com/Articles/43018/ASP-NET-GridView-with-search-option-SearchableGrid
Feedback to us
Develop and promote your apps in Windows Store
Mojorz
Member
3 Points
22 Posts
Re: Select all rows from gridview where column contain any words of a string
Nov 09, 2012 05:06 PM|LINK
Thanks this links were a great help
.
Thanks for your time .