Click here to Skip to main content
15,901,373 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i wanted to check SqlDataSource.SelectCommand is returns any results or not
ex
C#
is(SqlDatasource1.SelectCommand==empty)
{
Label.Text="No Record Found";
}
Posted
Updated 30-Oct-11 20:43pm
v2

Can you tell me exactly what is your error.


As far as your code is concerned,Change is to if and empty to String.Empty
 
Share this answer
 
u can use OnSelected event for SqlDataSource to check , u will find the proper code for your requirement at:
http://www.devcurry.com/2009/02/how-do-you-check-if-sqldatasource.html[^]
 
Share this answer
 
 
Share this answer
 
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900