以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  Dim dr As DataRow = DataTables("考试数据表").find("学号 = '" & ar("学号") & "' and 试卷号 = '" ar("试卷号") "'")  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=70108)

--  作者:zgjmost
--  发布时间:2015/6/16 1:56:00
--  Dim dr As DataRow = DataTables("考试数据表").find("学号 = '" & ar("学号") & "' and 试卷号 = '" ar("试卷号") "'")

 Dim dr As DataRow = DataTables("考试数据表").find("学号 = \'" & ar("学号") & "\' and 试卷号 = \'" ar("试卷号") "\'")

为什么报错?

 

完整代码如下:

 

For Each ar As Row In Tables("选课数据表").Rows
    If ar("纸考安排") = "纸考安排" And ar("是否排考") <> "不排考" Then
        Dim dr As DataRow = DataTables("考试数据表").find("学号 = \'" & ar("学号") & "\' and 试卷号 = \'" ar("试卷号") "\'")
        If dr IsNot Nothing Then
            dr("试卷名称") = ar("试卷名称")

 

报错如下:


 

 


此主题相关图片如下:qq截图20150616015533.png
按此在新窗口浏览图片

--  作者:9602084
--  发布时间:2015/6/16 8:35:00
--  
Dim dr As DataRow = DataTables("考试数据表").find("学号 = \'" & ar("学号") & "\' and 试卷号 = \'" & ar("试卷号")  & "\'")