带对象参数的ASP.NET回发 [英] ASP.NET Postback with object parameter

查看:92
本文介绍了带对象参数的ASP.NET回发的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在附近有一个带有客户文本框和搜索按钮的内容页面",单击搜索按钮后,将弹出一个新的弹出窗口,其中包含客户列表.在选择客户时,弹出窗口应返回客户对象.客户名称必须显示在内容页面"文本框中,并在标记中显示客户对象.

任何人都可以提供一个示例来打开一个新的弹出窗口并返回一个对象.
谢谢

解决方案

正如克里斯蒂安所说,您在这种情况下使用Javascript.看看这些链接.

http://www.openjs.com/tutorials/advanced_tutorial/popup.php [ ^ ]
http://www.velocityreviews.com/forums/t81473-pop-up- window-return-data.html [ ^ ]
http://wiki.asp.net /page.aspx/282/passing-value-from-popup-window-to-parent-form39s-textbox/ [
Can anyone provide an example to open a new popup window and return with an object.
Thanks

解决方案

As Christian said, you use Javascript for this scenario. Have a look at these links.

http://www.bennadel.com/blog/672-Passing-Data-From-A-Pop-Up-Window-To-A-Parent-Window-Using-ColdFusion-And-Javascript.htm[^]
http://www.openjs.com/tutorials/advanced_tutorial/popup.php[^]
http://www.velocityreviews.com/forums/t81473-pop-up-window-return-data.html[^]
http://wiki.asp.net/page.aspx/282/passing-value-from-popup-window-to-parent-form39s-textbox/[^]


You can use Modal PopUp extender from ajax contol toolkit.

In case you are intend to use this feature in more than one page, try to create a user control for this and use delegate to pass the selection from the usercontrol to your mainform.

Thanks,
Debata


There''s tons of articles on stuff like this. Surely there''s some on Code Project ? What''s on your page doesn''t really matter, it''s javascript that handles all of this, and would work the same no matter what framework you used to generate it.


这篇关于带对象参数的ASP.NET回发的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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