谁知道这个问题怎么解决后,连上一贴的分一起给.

xayzmb 2003-11-06 12:04:26
两个页面
第二个页面的一个数据是从第一个页面的文本框中取得的
为什么不能显示?
下面是代码:
第一个页面(asptop.asp)****************************************
<%language=vbscript%>
<%
response.write "<html>"
response.write "<title></title>"
response.write "<body>"
response.write "<form method=post action=callEXCEL.asp>"
response.write "<input type=""text"" name=""t1"">"
response.write "<input type=""submit"" name=""nn"" value=""kkkkkkkkk"" >"
response.write "</form>"
response.write "</body>"
response.write "</html>"
%>
'*************************************************
第二个页面(callEXCEL.asp)****************************************
<%@ Language=VBScript %>
<%
dim aa
aa = request.form("t1")

Response.Buffer = true
Response.ContentType = "application/vnd.ms-excel"

%>

<table border="1">
<tr>
<th bgcolor="red">项目 A</th>
<th>项目 B</th>
<th>合计</th>
<th>项目 C</th>
<th>项目 D</th>
<th>合计</th>
</tr>
<tr>
<td height="30" bgcolor="red"><% response.write aa %></td>
<td>4</td>
<td>5</td>
<td>6</td>
<td><%response.write aa%></td>
<td><font color="red">=sum(a2:e2)*100</font></td>
</tr>
<tr>
<td>2</td>
<td>1</td>
<td colspan="4"><font color="red">=sum(a3:b3)+f2</font></td>
</tr>
</table>
'*************************************************
但是如果不调用EXCEL则正常
还有就是如果直接给callEXCEL.asp中的变量aa赋值,就可以显示在EXCEL中
现在的问题是如何把从另一页面取得的数据
填入EXCEL中去

msn: xayzmb@msn.com
...全文
51 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
flc 2003-11-06
  • 打赏
  • 举报
回复
关注

7,789

社区成员

发帖
与我相关
我的任务
社区描述
VB 基础类
社区管理员
  • VB基础类社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧