What are the ways to close the current page and pass the value in the asp.net background?
This article mainly explains the "asp.net background closes the current page and the value of the methods are", the article explains the content is simple and clear, easy to learn and understand, the following please follow the editor's ideas slowly in-depth, together to study and learn "asp.net background to close the current page and transfer the value of what methods there are" it!
The first kind:
The copy code is as follows:
Response.Write ("window.close ();"); / / A dialog box pops up asking whether to close it.
The second kind:
The copy code is as follows:
Response.Write ("window.opener=null;window.close ();"); / / does not pop up the query
Pass the value to the parent page:
The copy code is as follows:
String value
Value = Request.Form ["myRadio"] .ToString ()
Response.Write ("window.opener.document.all.TextBox1.value='" + value + "'; opener=null;self.close ();")
Thank you for your reading, these are the contents of "asp.net background closes the current page and transmits values". After the study of this article, I believe you have a deeper understanding of what the method of closing the current page and passing values in the asp.net background has, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!