标题:[求助]关于批量添加到数据库的疑问
只看楼主
zmyzzz
Rank: 1
等 级:新手上路
帖 子:145
专家分:0
注 册:2005-9-21
 问题点数:0 回复次数:1 
[求助]关于批量添加到数据库的疑问

我是这么做的批量添加数据库:
A.asp
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>输入录入条数</title>
<style type="text/css">
<!--
.style1 {
font-family: "宋体";
font-size: 10pt;
}
-->
</style>
</head>

<body>
<div align="center">
<table width="400" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><form action="tiaozhang.asp" method="post" name="form1" class="style1">
您所要录入的条数:
<input type="text" name="recCnt">
<input type="submit" name="Submit" value="下一步&gt;&gt;">
</form></td>
</tr>
</table>
</div>
</body>
</html>
B.asp

<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
<style type="text/css">
<!--
.style1 {font-family: "宋体"}
.style2 {font-size: 10pt}
.style4 {font-family: "宋体"; font-size: 10pt; }
-->
</style>
</head>

<body>
<div align="center">
<%
dim sum,i
sum=cint(request("recCnt"))
%>
<table width="780" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="52"><div align="center" class="style1 style2">编号</div></td>
<td width="149"><div align="center" class="style4">手机号码</div></td>
<td width="147"><div align="center" class="style4">姓名</div></td>
<td width="113"><div align="center" class="style4">项目</div></td>
<td width="119"><div align="center" class="style4">金额</div></td>
<td width="200"><div align="center" class="style4">备注</div></td>
</tr>
</table>
<table width="780" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><form name="form1" method="post" action="tijiao.asp">
<%for i=1 to sum

%>
<table width="780" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="52"><div align="center"><%=i%></div></td>
<td width="148"><div align="center">
<input name="textphone" type="text" size="20" maxlength="11">
</div></td>
<td width="148"><div align="center">
<input name="textname" type="text" id="textname" size="20">
</div></td>
<td width="113"><div align="center">
<select name="xiangmu" id="xiangmu">
<option>选择项目</option>
<option value="1111">1111</option>
<option value="2222">2222</option>
</select>
</div></td>
<td width="118"><div align="center">
<input name="textjine" type="text" id="textjine" size="15">
</div></td>
<td width="201"><div align="center">
<input name="textnote" type="text" id="textnote">
</div></td>
</tr>
</table>
<div align="center">
<%
next%>
<input name="hsum" type="hidden" id="hsum" value="<%=sum%>">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="43%"><div align="right">
<input type="submit" name="Submit" value="提交">
</div></td>
<td width="15%">&nbsp;</td>
<td width="42%"><div align="left">
<input type="reset" name="Submit2" value="重置">
</div></td>
</tr>
</table>
</div>
</form></td>
</tr>
</table>
</div>
</body>
</html>
现在呢...我在B.asp中,做一个VB的判断,在点击提交时,检查是否所有的项目都填上了,可是由于是在A.asp中输入条数,怎么办呢?我该怎么判断阿??谢谢了......

[此贴子已经被hxfly于2005-11-22 14:07:11编辑过]

搜索更多相关主题的帖子: blank content PUBLIC target 数据库 
2005-11-22 13:44



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-34640-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.334900 second(s), 10 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved