Compilation Error
随风 2004-02-03 04:24:57 刚刚开始学习asp.net,遇到一个编译错误;请各位指教!
『部分源文件』
<%@ Page Language="VB" debug="true" ContentType="text/html" ResponseEncoding="gb2312" %>
<%@ import namespace="system.Data" %>
<%@ import nameSpace="system.Data.OLEDB" %>
<script runat="server">
Sub Page_Load(Src As Object, E As EventArgs)
Dim DBConn as OleDbConnection
Dim DBCommand as OleDbDataAdapter
Dim DSPageData as new DataSet
Dim I as Integer
Dim J as Integer
Dim TempID as String
Application("surveyID") = 1
DBConn = New OleDbConnection("PROVIDER=Microsoft.Jet.OLEDB.4.0;"
& "Data Source = " & server.mappath("/survey.mdb;")
DBCommand = New OleDbDataAdapter("select surveyname,surveyinstructions"
& "from surveys where surveyid = "
& application("surveyID"),DBConn)
『错误提示』
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: BC30198: ')' expected.
Source Error:
Line 12: Dim TempID as String
Line 13: Application("surveyID") = 1
Line 14: DBConn = New OleDbConnection("PROVIDER=Microsoft.Jet.OLEDB.4.0;"
Line 15: & "Data Source = " & server.mappath("/survey.mdb;")
Line 16: DBCommand = New OleDbDataAdapter("select surveyname,surveyinstructions"
错误停止在14行上。