开发者

How to implement parent-child windows and pass values from child to parent?

开发者 https://www.devze.com 2022-12-25 16:45 出处:网络
I am working on an ASP.NET MVC 2 application开发者_如何学编程. In one of my data entry forms, I have an \"employer\" field which has a \"search\" link next to it. When a user clicks on this link, ano

I am working on an ASP.NET MVC 2 application开发者_如何学编程.

In one of my data entry forms, I have an "employer" field which has a "search" link next to it. When a user clicks on this link, another window is opened with a search form. The user uses the search form to search for the correct employer. A list of employers is shown to the user. Currently, the user has to then copy and paste the correct employer from the child window into the original window.

I want to implement it so that each employer search result in the child window is a hyperlink. The user would then click on the correct employer and then the correct employer value would be populated in the original parent window employer field.

How would I go about implementing this in ASP.NET MVC 2?


Personally I would not use a new window but a modal dialog. jQuery UI has a nice modal dialog that you could load using AJAX

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号