sqlDatasource问题天气是否为空 [英] sqlDatasource problem weather empty or not

查看:74
本文介绍了sqlDatasource问题天气是否为空的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想检查SqlDataSource.SelectCommand是否返回任何结果

i wanted to check SqlDataSource.SelectCommand is returns any results or not
ex

is(SqlDatasource1.SelectCommand==empty)
{
Label.Text="No Record Found";
}

推荐答案

您能告诉我您的错误是什么吗?


就您的代码而言,更改为是否为String.Empty
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


您可以使用OnSelected事件对SqlDataSource进行检查,您将在以下位置找到适合您要求的代码:
http://www.devcurry.com/2009/02/how- do-you-check-if-sqldatasource.html [ ^ ]
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[^]


克里希纳,
http://forums.asp.net/t/1115646.aspx/1 [ ^ ]
Hi krishna,
http://forums.asp.net/t/1115646.aspx/1[^]


这篇关于sqlDatasource问题天气是否为空的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆