想实现用户填完表单,跳转到下一个页面后,还可以返回上一页面修改数据,但此过程不存储任何数据,只是暂存,当用户点击提交后才会存储。
问题很菜,不过困扰N久,感觉用Session或者Cookie都比较复杂,哪位有方便快捷的办法指点一下吧,多谢了!
问题很菜,不过困扰N久,感觉用Session或者Cookie都比较复杂,哪位有方便快捷的办法指点一下吧,多谢了!
解决方案 »
- 什么方法可以把一段服务器标签代码转换为html标签代码
- datalist嵌套 求绑定 子 datalist里lable 绑定的是“子datalist“的ID
- 求个把dataset转成JSON的函数
- Hashtable 的缓存时间是多少?
- 多级showModalDialog的问题
- EXCEL的读取问题,求教高手?
- VS.NET2003能不能编译.cs文件成.dll文件?如果可以怎么做?
- 请教asp.net后台类文件的工作机制
- The server does not support ASP.NET or ATL Server application.
- Bundleconfig中的js被缓存了,如何更新呢?
- ====100分,用HttpHandler还是用HttpModule?====
- 根据分辨率调整div的height
xxxx=(DataSet)Session["aaaa"]
数据建模、业务设计、用户界面是否合理?我的建议是,除了存在必须由服务器端控制的业务流程,请不要把数据分为几次提交
——可以用客户端脚本控制界面状态的切换如果部分流程必须由服务器端控制,为了在不同页面间保存数据状态,缓存是必须的,不同就是缓存放在服务器端还是客户端的问题1、客户端:cookie,viewstate(就是隐藏的input,适用于在一个页面内的多次回发间)
2、服务器端:会话缓存,应用程序缓存个人以为,在以上几种方案中,会话缓存是最直接有效的
then you can update your database
因为数据关系比较复杂,不完全是一对一存储,所以需要分开页面。
Session是最简单有效的,但相对于用户,有一个时间限制,如果超时,就等于没有作用了。
To uno(钢盅郭子):
“可以用客户端脚本控制界面状态的切换”具体如何操作呢?请赐教!
{
Wizard1.ActiveStepIndex = 1;
}
protected void btn2prev_Click(object sender, EventArgs e)
{
Wizard1.ActiveStepIndex = 0;
}
protected void btn3prev_Click(object sender, EventArgs e)
{
Wizard1.ActiveStepIndex = 1;
}
protected void btn4prev_Click(object sender, EventArgs e)
{
Wizard1.ActiveStepIndex = 2;
}
protected void btn5prev_Click(object sender, EventArgs e)
{
Wizard1.ActiveStepIndex = 3;
} protected void btn2next_Click(object sender, EventArgs e)
{
Wizard1.ActiveStepIndex = 2;
}
protected void btn3next_Click(object sender, EventArgs e)
{
Wizard1.ActiveStepIndex = 3;
}
protected void btn4next_Click(object sender, EventArgs e)
{
Wizard1.ActiveStepIndex = 4;
} 前台展示层:<asp:Wizard ID="Wizard1" runat="server" ActiveStepIndex="0">
<WizardSteps>
<asp:WizardStep ID="WizardStep1" runat="server" Title="">
<table width="780" cellpadding="0" cellspacing="0" border="0">
<tr>
<td colspan="4" align="left">第一步:基本信息</td>
</tr>
<tr>
<td style="width:180px"></td>
<td style="width:210px"></td>
<td style="width:180px"></td>
<td style="width:210px"></td>
</tr>
<tr>
<td colspan="4" align="right">
<asp:Button ID="btn1saveandnext" runat="server" Text="保存&下一步" OnClick="btn1saveandnext_Click" />
</td>
</tr>
</table>
</asp:WizardStep>
<asp:WizardStep ID="WizardStep2" runat="server" Title="">
<table width="780" cellpadding="0" cellspacing="0" border="0">
<tr>
<td colspan="4" align="left">第二步:教育背景</td>
</tr>
<tr>
<td style="width:180px"></td>
<td style="width:210px"></td>
<td style="width:180px"></td>
<td style="width:210px"></td>
</tr>
<tr>
<td colspan="4" align="right">
<asp:Button ID="btn2prev" runat="server" Text="上一步" OnClick="btn2prev_Click"/>
<asp:Button ID="btn2saveandnew" runat="server" Text="保存&新增" />
<asp:Button ID="btn2next" runat="server" Text="下一步" OnClick="btn2next_Click" />
</td>
</tr>
</table>
</asp:WizardStep>
<asp:WizardStep ID="WizardStep3" runat="server" Title="">
<table width="780" cellpadding="0" cellspacing="0" border="0">
<tr>
<td colspan="4" align="left">第三步:工作及项目信息</td>
</tr>
<tr>
<td style="width:180px"></td>
<td style="width:210px"></td>
<td style="width:180px"></td>
<td style="width:210px"></td>
</tr>
<tr>
<td colspan="4" align="right">
<asp:Button ID="btn3prev" runat="server" Text="上一步" OnClick="btn3prev_Click"/>
<asp:Button ID="btn3saveandnew" runat="server" Text="保存&新增" />
<asp:Button ID="btn3next" runat="server" Text="下一步" OnClick="btn3next_Click"/>
</td>
</tr>
</table>
</asp:WizardStep>
<asp:WizardStep ID="WizardStep4" runat="server" Title="">
<table width="780" cellpadding="0" cellspacing="0" border="0">
<tr>
<td colspan="4" align="left">第四步:掌握技术</td>
</tr>
<tr>
<td style="width:180px"></td>
<td style="width:210px"></td>
<td style="width:180px"></td>
<td style="width:210px"></td>
</tr>
<tr>
<td colspan="4" align="right">
<asp:Button ID="btn4prev" runat="server" Text="上一步" OnClick="btn4prev_Click"/>
<asp:Button ID="btn4saveandnew" runat="server" Text="保存&新增" />
<asp:Button ID="btn4next" runat="server" Text="下一步" OnClick="btn4next_Click"/>
</td>
</tr>
</table>
</asp:WizardStep>
<asp:WizardStep ID="WizardStep5" runat="server" Title="">
<table width="780" cellpadding="0" cellspacing="0" border="0">
<tr>
<td colspan="4" align="left">第五步:职业技能及素质描述</td>
</tr>
<tr>
<td style="width:180px"></td>
<td style="width:210px"></td>
<td style="width:180px"></td>
<td style="width:210px"></td>
</tr>
<tr>
<td colspan="4" align="right">
<asp:Button ID="btn5prev" runat="server" Text="上一步" OnClick="btn5prev_Click"/>
<asp:Button ID="btn5finish" runat="server" Text="完成" />
</td>
</tr>
</table>
</asp:WizardStep>
</WizardSteps>
<StartNavigationTemplate>
</StartNavigationTemplate>
<StepNavigationTemplate>
</StepNavigationTemplate>
<FinishNavigationTemplate>
</FinishNavigationTemplate>
<SideBarTemplate>
</SideBarTemplate>
</asp:Wizard>