在线等,看一下是什么原因,第一次写CLASS
<%@ LANGUAGE="VBSCRIPT" %>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" Type="text/css" href="css/style.css">
<link rel="stylesheet" Type="text/css" href="css/Register.css">
<title>日中纺WEB管理中心-用户注册</title>
</head>
<body topmargin="50">
<!--#include file="lib/conn.inc"-->
<%
'region 建立注册用户对象
'==========================================================
'创建数据集对象
Set rs=Server.CreateObject("ADODB.recordset")
Class Register
'#字段集#
'------------------------------------
Public _company
'------------------------------------
'#属性集#
'------------------------------------
'设置公司名
Public Property Let Company(CO_Code)
_company = CO_Code
End Property
'取出公司名
Public Property Get Company()
Company = _company
End Property
'------------------------------------
'#方法集#
'------------------------------------
'创建得到部门列表
Public Function getDeptList(coltd)
dim sql
'创建字典对象
Set objDictionary = server.CreateObject("Scripting.Dictionary")
sql = "SELECT Dept_Code,Dept_Name FROM dbo.pb_Department WHERE Company_Code='"&coltd&"'"
Set rs = Conn.Execute(sql)
Do While Not Rs.EOF
objDictionary.Add rs(0),rs(1)
rs.MoveNext
Loop
Rs.Close
getDeptList = objDictionary
End Function
'------------------------------------
End Class
'==========================================================
'end region
%>
<form Method="get" Action="register.asp?">
<table width="650" border="0" cellpadding="0" cellspacing="0" class="table" align="center">
<tr>
<td colspan="2" class="bottom"><!--#INCLUDE FILE=FrameHead.htm--></td>
</tr>
错误信息:
Microsoft VBScript 编译器错误 错误 '800a0408'
无效字符
/sunrise/admin/Register.asp,行 20
Public _company
--------^