如何在C#中将数据从一种形式传递到另一种形式? [英] How to pass data from one form to another in C#?

查看:109
本文介绍了如何在C#中将数据从一种形式传递到另一种形式?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我已经在C#.net4.0中创建了一个Web应用程序.在该应用程序中,我希望将DATASET中的数据从一种形式传递给另一种形式,并且希望将该数据放置在第二种形式的文本框中.我怎样才能做到这一点?请帮我

谢谢您

Hi
I have created a web application in C# .net4.0.In that application, i want to pass data present in a DATASET from one form to another and i want to place that data in the textboxes present in the 2nd form. How can i do that? Plz help me

Thanking you

推荐答案


您可以使用Session
Hi ,
You can use Session
//for assign
       DataSet ds = new DataSet();
       Session.Add("Name", ds);
       // for retrieve
       ds = (DataSet)Session["Name"];


在ASP.NET中浏览会话 [ ASP.NET中的会话管理选项 [ ASP.NET中的会话管理 [ ASP.NET会话管理内部 [ http://msdn.microsoft.com/en-us/library/ms178581.aspx [ ^ ]
最好的问候
M.Mitwalli


Exploring Session in ASP.NET[^]
Session management options in ASP.NET[^]
Session Management in ASP.NET[^]
ASP.NET Session Management Internals[^]
http://msdn.microsoft.com/en-us/library/ms178581.aspx[^]
Best Regards
M.Mitwalli


请参阅以下内容:


http://www.dotnetspider.com/forum/164501- how-pass-dataset-from-one-form-another.aspx [ http://www.homeandlearn.co.uk/csharp/csharp_s12p6.html [ ^ ]
Refer these:


http://www.dotnetspider.com/forum/164501-how-pass-dataset-from-one-form-another.aspx[^]


http://www.homeandlearn.co.uk/csharp/csharp_s12p6.html[^]


浏览状态管理技术
ASP.NET中的状态管理 [如何通过 [
Go through State Management Techniques
State Management in ASP.NET[^]

how to pass the more textbox value from one form to another form in asp.net?[^]


这篇关于如何在C#中将数据从一种形式传递到另一种形式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆