Computers/Language
2012. 9. 6. 20:24
C# - 윈도우 폼에서 팝업 윈도우 만들기
http://www.codeproject.com/Questions/231247/How-to-create-a-Popup-Window-in-Csharp-in-Windows
Let's say you called your popup window class "PopupWindow". You created it by right-clicking on your project in project explorer and chosing "Add new Windows Form". Then you added a text box and an "Ok"-Button.
You also added a property to your form so that you can later gain access to the data the user entered in the text box.
Collapse | Copy Code
public class PopupWindow { public string EnteredText { get { return( textBox.Text ); } } }Now you use your new class like this:
Collapse | Copy Code
PopupWindow popup = new PopupWindow();
popup.ShowDialog();
string userEnteredText = popup.EnteredText;
popup.Dispose();