请教一个关于函数的问题。
我写了一个函数,如下:
'**************
'函数名 ifExist
'传参:Source_Table 数据表名;Source_col 数据列;Item_Searched 待搜索项目;
'功能:检查指定项目在指定数据表中是否存在
'**************
dim Source_Table
dim Item_Searched
dim Source_col
function ifExist(byVal Item_Searched,byVal Source_col,byVal Source_Table)
dim tmprs
'response.write("select Source_col from Source_Table where Source_col='Item_Searched'")
'response.end
set tmprs=conn.execute("select Source_col from Source_Table where Source_col='Item_Searched'")
if tmprs.bof and tmprs.eof then
ifExist="0"
else
ifExist="1"
end if
tmprs.close
set tmprs=nothing
end function
在做传值调用的时候出现如下错误:
错误的参数个数或无效的参数属性值
我调用的那行程序为:ifExist '1','Topic','Topic'
哪儿错了??谢谢各位帮助!