. NET dialog box

Source: Internet
Author: User

Add "<base target =" _ self "/>" to the Handle the problem of sending a new page

Main functions:

Click a button on the webpage to bring up a page window. Select the value of the page window to close the window. The page will get the value.
Copy codeThe Code is as follows:
// Process the selected values on the page B

<Input type = "button" id = "btnClose" value = "confirm and close the window" onclick = "closeWin ()"/>

Function closeWin (){

// Upload the value of interface B to interface
Window. returnValue = totalCount;
Window. close ();
}
// Select A value for interface
Function showUnitDialog2 (id ){
Var rdm = Math. random ();

// Open interface B
Var result = window. showModalDialog ("GoodsStocketacke. aspx? Id = "+ id +" & t = "+ rdm," inventory details "," dialogWidth = 800px; dialogHeight = 500px; center = 1 ");

// Accept the value of interface B

If (result ){
$ ("# TxtRealCount"). val (result );
$ ("# TxtRealCount"). attr ("readonly", "true ");
$ ("# TbUnit tr: eq (1) td: eq (3)" example .html (result );
InitButton ();
}
}

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.