日期:2014-05-17  浏览次数:20930 次

用ASP做个查询系统
现想用asp做个简单的查询系统,结构如下:
1.cx.xls中内容:
NO YF XM MA xm01 xm02 xm03
序号 月份 姓名 密码 项目01 项目01 项目01
序号 月份 姓名 密码 项目01 项目01 项目01
001 201006 AAA AAA01 xm01AAA xm02AAA xm03AAA
002 201006 BBB BBB01 xm01BBB xm02BBB xm03BBB
003 201006 BBB CCC01 xm01CCC xm02CCC xm03CCC

2.cx.mdb中内容:
ID NO YF XM MA xm01 xm02 xm03
1 序号 月份 姓名 密码 项目01 项目01 项目01
2 序号 月份 姓名 密码 项目01 项目01 项目01
3 001 201006 AAA AAA01 xm01AAA xm02AAA xm03AAA
4 002 201006 BBB BBB01 xm01BBB xm02BBB xm03BBB
5 003 201006 BBB CCC01 xm01CCC xm02CCC xm03CCC

3. index.asp中内容

<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>查询系统</title>
</head>

<body>
<table width='100%' height='100%' border='0' cellpadding='0' cellspacing='0'><tr><td>
<form name='Login' action='cx.asp' method='post' target='_parent' onSubmit='return CheckForm();'>
  <table width='100%' border='0' cellpadding='0' cellspacing='0'>
  <tr>
  <td width='219' height='164' background='login_01.gif'></td>
  <td width='64' height='164' background='login_02.gif'></td>
  <td valign='top' background='login_03.gif'><table border='0' cellpadding='0' cellspacing='0'>
  <tr>
  <td><table width='100%' border='0' cellpadding='0' cellspacing='0'>
  <tr>
  <td width='270' height='79' background='login_04.gif'></td>
  <td width='150' height='79' background='login_05.gif'></td>
  <td valign='top'><table width='100%' border='0' cellpadding='0' cellspacing='0'>
  <tr>
  <td height='21'></td>
  <td></td>
  </tr>
  <tr>
  <td><input type='hidden' name='Action' value='Login' /><input type='image' name='Submit' src='login_06.gif' style='width:50px; HEIGHT: 50px;' /></td>
  <td width='58' height='50' background='login_07.gif'></td>
  </tr>
  </table></td>
  </tr>
  </table></td>
  </tr>
  <tr>
  <td height='85'><table border='0' cellspacing='0' cellpadding='0'>
  <tr>
  <td width='22' rowspan='2' valign='bottom'><img src='login_08.gif' alt='' width="20" height="30" /></td>
  <td width='80'><font color='#ffffff'>姓名:</font></td>
  <td width='22' rowspan='2' valign='bottom'><img src='login_09.gif' alt='' width="20" height="30" /></td>
  <td width='80'><font color='#ffffff'>密码:</font></td>
  </tr>
  <tr>
  <td><input name='UserName' type='text' id='UserName' maxlength='20' style='width:70px; BORDER-RIGHT: #F7F7F7 0px solid; BORDER-TOP: #F7F7F7 0px solid; FONT-SIZE: 9pt; BORDER-LEFT: #F7F7F7 0px solid; BORDER-BOTTOM: #c0c0c0 1px solid;