正在学习Asp.net,在涉及到数据库连接的一个例子中,程序出现了问题
原码如下:
    <%@ Import Namespace="System.Data" %>
    <%@ Import Namespace="System.Data.SQL" %>
    <html>
    <script language="VB" runat="server">
    Sub Page_Load(Src As Object, E As EventArgs) 
        Dim DS As DataSet
        Dim MyConnection As SQLConnection
        Dim MyCommand As SQLDataSetCommand
    
        MyConnection = New SQLConnection("server='Grubby';uid=sa;pwd=********;database=MuOnline")
         
        MyCommand = New SQLDataSetCommand("select * from Character",MyConnection)              
        DS = New DataSet()
        MyCommand.FillDataSet(ds, "Character")
        MyDataGrid.DataSource=ds.Tables("Character").DefaultView
        MyDataGrid.DataBind()
    End Sub
    </script>
<center>
<body>
  <h3><font face="Verdana">Page_load事件演示</font></h3>
  <ASP:DataGrid id="MyDataGrid" runat="server"
    Width="600"
    BackColor="white" 
    BorderColor="black"
    ShowFooter="false" 
    CellPadding=3 
    CellSpacing="0"
    Font-Name="Verdana"
    Font-Size="8pt"
    HeaderStyle-BackColor="#aaaadd"
    MaintainState="false" />
</body>
</center>
</html>运行时出错:编译器错误信息: BC30002: 未定义类型“SQLConnection”。源错误:行 5:      Sub Page_Load(Src As Object, E As EventArgs) 
行 6:          Dim DS As DataSet
行 7:          Dim MyConnection As SQLConnection
行 8:          Dim MyCommand As SQLDataSetCommand
行 9: //行 7:有问题详细错误:     
Microsoft (R) Visual Basic .NET 编译器版本 7.00.9466
用于 Microsoft (R) .NET 框架版本 1.00.3705
版权所有 (C) Microsoft Corporation 1987-2001。保留所有权利。C:\WINDOWS\Microsoft.NET\Framework\v1.0.3705\Temporary ASP.NET Files\aspx\4768a57c\9366c2ac\dbzt1zda.0.vb(20) : error BC30466: 无法找到 Imports“System.Data.SQL”的命名空间或类型“SQL”。我装了.net环境,为什么说找不到“System.Data.SQL”的命名空间或类型“SQL”?