Set default button for MessageBox : MessageBox « GUI « VB.Net Tutorial

VB.Net Tutorial
1. Language Basics
2. Data Type
3. Operator
4. Statements
5. Date Time
6. Class Module
7. Development
8. Collections
9. Generics
10. Attributes
11. Event
12. Stream File
13. GUI
14. GUI Applications
15. 2D Graphics
16. I18N Internationlization
17. Reflection
18. Regular Expressions
19. Security
20. Socket Network
21. Thread
22. Windows
23. XML
24. Database ADO.net
25. Design Patterns
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
VB.Net Tutorial » GUI » MessageBox 
13. 59. 7. Set default button for MessageBox
Set default button for MessageBox
Imports System.Windows.Forms

public class MessageBoxDefaultButtonDemo
   public Shared Sub Main
      Dim answer As DialogResult
      answer = MessageBox.Show("A""B",MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question, _
         MessageBoxDefaultButton.Button2)
   End Sub
End class
13. 59. MessageBox
13. 59. 1. MessageBox with Message onlyMessageBox with Message only
13. 59. 2. MessageBox with Message and TitleMessageBox with Message and Title
13. 59. 3. MessageBox with OK, Cancel button and InformationMessageBox with OK, Cancel button and Information
13. 59. 4. MessageBox with Yes No Cancel button and Question iconMessageBox with Yes No Cancel button and Question icon
13. 59. 5. MessageBox OK and Cancel ButtonMessageBox OK and Cancel Button
13. 59. 6. MessageBox: Abort, Retry, Ignore buttons and Warning iconMessageBox: Abort, Retry, Ignore buttons and Warning icon
13. 59. 7. Set default button for MessageBoxSet default button for MessageBox
13. 59. 8. Displaying square root of 2 in dialog.
13. 59. 9. Return value from MessageBox
13. 59. 10. MessageBox Icon and ButtonMessageBox Icon and Button
13. 59. 11. Custom your MessageBoxCustom your MessageBox
13. 59. 12. Create MessageBox dynamicallyCreate MessageBox dynamically
w_w_w_.__ja_v__a_2__s.__c_o_m__ | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.