首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > VB >

至少一个参数没有指定值?解决方案

2012-01-07 
至少一个参数没有指定值?代码如下:PrivateSubDataCombo1_Click(AreaAsInteger)DimstrqueryAsStringIfDataC

至少一个参数没有指定值?
代码如下:

Private   Sub   DataCombo1_Click(Area   As   Integer)
Dim   strquery   As   String
If   DataCombo1.Text   =   " "   Then
Exit   Sub
End   If
strquery   =   "select   *   from   [application]   where   [dept]=datecombo1.BoundText "
With   Adodc2
.RecordSource   =   strquery
.Refresh
End   With
End   Sub

提示至少一个参数没有指定值,对象 "refresh "的方法 "iadodc "失败
[dept]是部门名称(中文字符)
上面SQL语句我该如何写?
谢谢


[解决办法]
strquery = "select * from [application] where [dept]= ' "& datecombo1.BoundText & " ' "

热点排行