SlideShare a Scribd company logo
FEDT Presentation
GGS INDRAPRASTH UNIVERSITY
Submitted to Submitted
MANISH
BCA E1 2016-2019
TOPIC
Button control in VB.NET
VISUAL BASIC INTERFACE
When we write a Visual Basic program, you first have to
design the user interface. Essentially, a Visual Basic user
interface consists of objects that you place on the screen.
The common elements of a Visual Basic user interface
consist of the following:
•Forms (also known as windows)
•Buttons (such as command buttons and radio buttons)
•Boxes (such as text boxes and check boxes)
•Labels
•Pictures (such as icons and graphics)
BUTTON
The button control is your standard GUI function, usually
used to confirm something or trigger an event. Such uses
for a button include search engine's, dialog boxes, message
boxes, etc. They are usually used to give the user an option
or choice.
Button can be clicked by a mouse click or by pressing
ENTER or ESC keys.
CREATING A BUTTON
BY DRAG & DROP
To create a Button control, you simply drag and drop a
Button control from Toolbox to Form in Visual Studio.
CREATING A BUTTON
AT RUN-TIME
VB.Net allow us to add button at run time by typing code:-
Dim button1 as new button
Me.Controls.Add(button1)
PROPERTIES OF THE
BUTTON CONTROL
1 AutoSizeMode Gets or sets the mode by which the Button
automatically resizes itself.
2 BackColor Gets or sets the background color of the
control.
3 BackgroundImage Gets or sets the background image
displayed in the control.
4 DialogResult Gets or sets a value that is returned to the
parent form when the button is clicked.
This is used while creating dialog boxes.
5 ForeColor Gets or sets the foreground color of the
control.
6 Image Gets or sets the image that is displayed on
a button control.
7 Location Gets or sets the coordinates of the upper-
left corner of the control relative to the
upper-left corner of its container.
8 TabIndex Gets or sets the tab order of the control
within its container.
9 Text Gets or sets the text associated with this
control.
WORKING OF
BUTTON
When we click the button a handler is executed.
Private Sub Button1_Click(sender As Object, e As EventArgs)
Handles Button1.Click
After it we can give instructions that will be done after the button
click.
Button sub is End by using End sub
EXAMPLE
Check odd even.
Interface
CODE
Public Class Form1
Private Sub Button1_Click(sender As Object, e As EventArgs)
Handles Button1.Click
Dim a As Integer = TextBox1.Text
If a Mod 2 = 0 Then
MsgBox("No is even")
Else
MsgBox("No is odd")
End If
End Sub
End Class
Statement that will be
executed after button
click
OUTPUT
THANK YOU
Ad

More Related Content

What's hot (20)

Radio button
Radio buttonRadio button
Radio button
chauhankapil
 
Asp.net state management
Asp.net state managementAsp.net state management
Asp.net state management
priya Nithya
 
JAVA AWT
JAVA AWTJAVA AWT
JAVA AWT
shanmuga rajan
 
Basic knowledge on html and dhtml
 Basic knowledge on html and dhtml Basic knowledge on html and dhtml
Basic knowledge on html and dhtml
Suryakanta Behera
 
JavaScript - Chapter 6 - Basic Functions
 JavaScript - Chapter 6 - Basic Functions JavaScript - Chapter 6 - Basic Functions
JavaScript - Chapter 6 - Basic Functions
WebStackAcademy
 
Tkinter_GUI_Programming_in_Python.pdf
Tkinter_GUI_Programming_in_Python.pdfTkinter_GUI_Programming_in_Python.pdf
Tkinter_GUI_Programming_in_Python.pdf
ArielManzano3
 
Cookies in servlets.ppt
Cookies in servlets.pptCookies in servlets.ppt
Cookies in servlets.ppt
Swetha S
 
Event handling
Event handlingEvent handling
Event handling
Shree M.L.Kakadiya MCA mahila college, Amreli
 
android activity
android activityandroid activity
android activity
Deepa Rani
 
Document Object Model
Document Object ModelDocument Object Model
Document Object Model
baabtra.com - No. 1 supplier of quality freshers
 
DBMS Keys
DBMS KeysDBMS Keys
DBMS Keys
Tarun Maheshwari
 
2D Array
2D Array 2D Array
2D Array
Ehatsham Riaz
 
Data controls ppt
Data controls pptData controls ppt
Data controls ppt
Iblesoft
 
3 tier architecture
3 tier architecture3 tier architecture
3 tier architecture
baabtra.com - No. 1 supplier of quality freshers
 
Sessions and cookies
Sessions and cookiesSessions and cookies
Sessions and cookies
www.netgains.org
 
Character generation techniques
Character generation techniquesCharacter generation techniques
Character generation techniques
Mani Kanth
 
7. check box control
7. check box control7. check box control
7. check box control
chauhankapil
 
Unit iv
Unit ivUnit iv
Unit iv
bhushan_adavi
 
File in C language
File in C languageFile in C language
File in C language
Manash Kumar Mondal
 
Sdi & mdi
Sdi & mdiSdi & mdi
Sdi & mdi
BABAVALI S
 

Similar to Buttons In .net Visual Basic (20)

Vp lecture1 ararat
Vp lecture1 araratVp lecture1 ararat
Vp lecture1 ararat
Saman M. Almufti
 
Vs c# lecture1
Vs c# lecture1Vs c# lecture1
Vs c# lecture1
Saman M. Almufti
 
Visual Basic IDE Introduction
Visual Basic IDE IntroductionVisual Basic IDE Introduction
Visual Basic IDE Introduction
Ahllen Javier
 
Visual Basic IDE Intro.pdf
Visual Basic IDE Intro.pdfVisual Basic IDE Intro.pdf
Visual Basic IDE Intro.pdf
sheenmarie0212
 
Lecture 3 INTRODUCTION TO COMPUTER
Lecture 3 INTRODUCTION TO COMPUTERLecture 3 INTRODUCTION TO COMPUTER
Lecture 3 INTRODUCTION TO COMPUTER
Sultan Omar Shige
 
Point&Click
Point&ClickPoint&Click
Point&Click
Small Business Solutions Enterprises, Inc
 
Pong 5a_pdf programmation dans scratch et mblock
Pong 5a_pdf programmation dans scratch et mblockPong 5a_pdf programmation dans scratch et mblock
Pong 5a_pdf programmation dans scratch et mblock
ParlonsdeTout1
 
VB PPT by ADI PART4.pdf
VB PPT by ADI PART4.pdfVB PPT by ADI PART4.pdf
VB PPT by ADI PART4.pdf
AdiseshaK
 
VB PPT by ADI PART4.pdf
VB PPT by ADI PART4.pdfVB PPT by ADI PART4.pdf
VB PPT by ADI PART4.pdf
Prof. Dr. K. Adisesha
 
lesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptxlesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptx
theriverflows213
 
lesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptxlesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptx
theriverflows213
 
Introduction to programming using Visual Basic 6
Introduction to programming using Visual Basic 6Introduction to programming using Visual Basic 6
Introduction to programming using Visual Basic 6
Jeanie Arnoco
 
Basic After Effect & Animation GIF (J&T Express)
Basic After Effect & Animation GIF (J&T Express)Basic After Effect & Animation GIF (J&T Express)
Basic After Effect & Animation GIF (J&T Express)
IzzuwanIsmail
 
Gui builder
Gui builderGui builder
Gui builder
learnt
 
Bea's powerpoint presentation
Bea's powerpoint presentationBea's powerpoint presentation
Bea's powerpoint presentation
Bea Nelene A. Que
 
Bea's powerpoint presentation
Bea's powerpoint presentationBea's powerpoint presentation
Bea's powerpoint presentation
Bea Nelene A. Que
 
Windowforms controls c#
Windowforms controls c#Windowforms controls c#
Windowforms controls c#
prabhu rajendran
 
Introduction
IntroductionIntroduction
Introduction
شكسبير ويليام
 
The visual studio start page is shown in the figure below
The visual studio start page is shown in the figure belowThe visual studio start page is shown in the figure below
The visual studio start page is shown in the figure below
Tan Ps
 
Living in the IT Era L3.pptx
Living in the IT Era L3.pptxLiving in the IT Era L3.pptx
Living in the IT Era L3.pptx
elmervirtudazo1
 
Visual Basic IDE Introduction
Visual Basic IDE IntroductionVisual Basic IDE Introduction
Visual Basic IDE Introduction
Ahllen Javier
 
Visual Basic IDE Intro.pdf
Visual Basic IDE Intro.pdfVisual Basic IDE Intro.pdf
Visual Basic IDE Intro.pdf
sheenmarie0212
 
Lecture 3 INTRODUCTION TO COMPUTER
Lecture 3 INTRODUCTION TO COMPUTERLecture 3 INTRODUCTION TO COMPUTER
Lecture 3 INTRODUCTION TO COMPUTER
Sultan Omar Shige
 
Pong 5a_pdf programmation dans scratch et mblock
Pong 5a_pdf programmation dans scratch et mblockPong 5a_pdf programmation dans scratch et mblock
Pong 5a_pdf programmation dans scratch et mblock
ParlonsdeTout1
 
VB PPT by ADI PART4.pdf
VB PPT by ADI PART4.pdfVB PPT by ADI PART4.pdf
VB PPT by ADI PART4.pdf
AdiseshaK
 
lesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptxlesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptx
theriverflows213
 
lesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptxlesson-9-Building-Windows-Form-Application.pptx
lesson-9-Building-Windows-Form-Application.pptx
theriverflows213
 
Introduction to programming using Visual Basic 6
Introduction to programming using Visual Basic 6Introduction to programming using Visual Basic 6
Introduction to programming using Visual Basic 6
Jeanie Arnoco
 
Basic After Effect & Animation GIF (J&T Express)
Basic After Effect & Animation GIF (J&T Express)Basic After Effect & Animation GIF (J&T Express)
Basic After Effect & Animation GIF (J&T Express)
IzzuwanIsmail
 
Gui builder
Gui builderGui builder
Gui builder
learnt
 
Bea's powerpoint presentation
Bea's powerpoint presentationBea's powerpoint presentation
Bea's powerpoint presentation
Bea Nelene A. Que
 
Bea's powerpoint presentation
Bea's powerpoint presentationBea's powerpoint presentation
Bea's powerpoint presentation
Bea Nelene A. Que
 
The visual studio start page is shown in the figure below
The visual studio start page is shown in the figure belowThe visual studio start page is shown in the figure below
The visual studio start page is shown in the figure below
Tan Ps
 
Living in the IT Era L3.pptx
Living in the IT Era L3.pptxLiving in the IT Era L3.pptx
Living in the IT Era L3.pptx
elmervirtudazo1
 
Ad

More from manish maurya (6)

Do,Do while loop .net Visual Basic
Do,Do while loop .net Visual BasicDo,Do while loop .net Visual Basic
Do,Do while loop .net Visual Basic
manish maurya
 
Recursive Function PPT C lang
Recursive Function PPT C langRecursive Function PPT C lang
Recursive Function PPT C lang
manish maurya
 
Function-Definition, Need, Declaration, Definition, Arguments, Return Value
Function-Definition, Need, Declaration, Definition, Arguments, Return ValueFunction-Definition, Need, Declaration, Definition, Arguments, Return Value
Function-Definition, Need, Declaration, Definition, Arguments, Return Value
manish maurya
 
Fast and secure protocol FASP
Fast and secure protocol FASPFast and secure protocol FASP
Fast and secure protocol FASP
manish maurya
 
ISO 14000 Environmental Management System
ISO 14000  Environmental Management SystemISO 14000  Environmental Management System
ISO 14000 Environmental Management System
manish maurya
 
MICR magnetic ink character reader
MICR magnetic ink character readerMICR magnetic ink character reader
MICR magnetic ink character reader
manish maurya
 
Do,Do while loop .net Visual Basic
Do,Do while loop .net Visual BasicDo,Do while loop .net Visual Basic
Do,Do while loop .net Visual Basic
manish maurya
 
Recursive Function PPT C lang
Recursive Function PPT C langRecursive Function PPT C lang
Recursive Function PPT C lang
manish maurya
 
Function-Definition, Need, Declaration, Definition, Arguments, Return Value
Function-Definition, Need, Declaration, Definition, Arguments, Return ValueFunction-Definition, Need, Declaration, Definition, Arguments, Return Value
Function-Definition, Need, Declaration, Definition, Arguments, Return Value
manish maurya
 
Fast and secure protocol FASP
Fast and secure protocol FASPFast and secure protocol FASP
Fast and secure protocol FASP
manish maurya
 
ISO 14000 Environmental Management System
ISO 14000  Environmental Management SystemISO 14000  Environmental Management System
ISO 14000 Environmental Management System
manish maurya
 
MICR magnetic ink character reader
MICR magnetic ink character readerMICR magnetic ink character reader
MICR magnetic ink character reader
manish maurya
 
Ad

Recently uploaded (20)

211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
inmishra17121973
 
Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...
Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...
Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...
Journal of Soft Computing in Civil Engineering
 
Introduction to FLUID MECHANICS & KINEMATICS
Introduction to FLUID MECHANICS &  KINEMATICSIntroduction to FLUID MECHANICS &  KINEMATICS
Introduction to FLUID MECHANICS & KINEMATICS
narayanaswamygdas
 
Smart_Storage_Systems_Production_Engineering.pptx
Smart_Storage_Systems_Production_Engineering.pptxSmart_Storage_Systems_Production_Engineering.pptx
Smart_Storage_Systems_Production_Engineering.pptx
rushikeshnavghare94
 
theory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptxtheory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptx
sanchezvanessa7896
 
ELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdfELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdf
Shiju Jacob
 
Degree_of_Automation.pdf for Instrumentation and industrial specialist
Degree_of_Automation.pdf for  Instrumentation  and industrial specialistDegree_of_Automation.pdf for  Instrumentation  and industrial specialist
Degree_of_Automation.pdf for Instrumentation and industrial specialist
shreyabhosale19
 
Introduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptxIntroduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptx
AS1920
 
Data Structures_Searching and Sorting.pptx
Data Structures_Searching and Sorting.pptxData Structures_Searching and Sorting.pptx
Data Structures_Searching and Sorting.pptx
RushaliDeshmukh2
 
Mathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdfMathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdf
TalhaShahid49
 
IntroSlides-April-BuildWithAI-VertexAI.pdf
IntroSlides-April-BuildWithAI-VertexAI.pdfIntroSlides-April-BuildWithAI-VertexAI.pdf
IntroSlides-April-BuildWithAI-VertexAI.pdf
Luiz Carneiro
 
Value Stream Mapping Worskshops for Intelligent Continuous Security
Value Stream Mapping Worskshops for Intelligent Continuous SecurityValue Stream Mapping Worskshops for Intelligent Continuous Security
Value Stream Mapping Worskshops for Intelligent Continuous Security
Marc Hornbeek
 
Smart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineeringSmart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineering
rushikeshnavghare94
 
The Gaussian Process Modeling Module in UQLab
The Gaussian Process Modeling Module in UQLabThe Gaussian Process Modeling Module in UQLab
The Gaussian Process Modeling Module in UQLab
Journal of Soft Computing in Civil Engineering
 
Data Structures_Linear data structures Linked Lists.pptx
Data Structures_Linear data structures Linked Lists.pptxData Structures_Linear data structures Linked Lists.pptx
Data Structures_Linear data structures Linked Lists.pptx
RushaliDeshmukh2
 
ADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITY
ADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITYADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITY
ADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITY
ijscai
 
Compiler Design_Lexical Analysis phase.pptx
Compiler Design_Lexical Analysis phase.pptxCompiler Design_Lexical Analysis phase.pptx
Compiler Design_Lexical Analysis phase.pptx
RushaliDeshmukh2
 
Metal alkyne complexes.pptx in chemistry
Metal alkyne complexes.pptx in chemistryMetal alkyne complexes.pptx in chemistry
Metal alkyne complexes.pptx in chemistry
mee23nu
 
DSP and MV the Color image processing.ppt
DSP and MV the  Color image processing.pptDSP and MV the  Color image processing.ppt
DSP and MV the Color image processing.ppt
HafizAhamed8
 
LECTURE-16 EARTHEN DAM - II.pptx it's uses
LECTURE-16 EARTHEN DAM - II.pptx it's usesLECTURE-16 EARTHEN DAM - II.pptx it's uses
LECTURE-16 EARTHEN DAM - II.pptx it's uses
CLokeshBehera123
 
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
inmishra17121973
 
Introduction to FLUID MECHANICS & KINEMATICS
Introduction to FLUID MECHANICS &  KINEMATICSIntroduction to FLUID MECHANICS &  KINEMATICS
Introduction to FLUID MECHANICS & KINEMATICS
narayanaswamygdas
 
Smart_Storage_Systems_Production_Engineering.pptx
Smart_Storage_Systems_Production_Engineering.pptxSmart_Storage_Systems_Production_Engineering.pptx
Smart_Storage_Systems_Production_Engineering.pptx
rushikeshnavghare94
 
theory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptxtheory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptx
sanchezvanessa7896
 
ELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdfELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdf
Shiju Jacob
 
Degree_of_Automation.pdf for Instrumentation and industrial specialist
Degree_of_Automation.pdf for  Instrumentation  and industrial specialistDegree_of_Automation.pdf for  Instrumentation  and industrial specialist
Degree_of_Automation.pdf for Instrumentation and industrial specialist
shreyabhosale19
 
Introduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptxIntroduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptx
AS1920
 
Data Structures_Searching and Sorting.pptx
Data Structures_Searching and Sorting.pptxData Structures_Searching and Sorting.pptx
Data Structures_Searching and Sorting.pptx
RushaliDeshmukh2
 
Mathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdfMathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdf
TalhaShahid49
 
IntroSlides-April-BuildWithAI-VertexAI.pdf
IntroSlides-April-BuildWithAI-VertexAI.pdfIntroSlides-April-BuildWithAI-VertexAI.pdf
IntroSlides-April-BuildWithAI-VertexAI.pdf
Luiz Carneiro
 
Value Stream Mapping Worskshops for Intelligent Continuous Security
Value Stream Mapping Worskshops for Intelligent Continuous SecurityValue Stream Mapping Worskshops for Intelligent Continuous Security
Value Stream Mapping Worskshops for Intelligent Continuous Security
Marc Hornbeek
 
Smart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineeringSmart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineering
rushikeshnavghare94
 
Data Structures_Linear data structures Linked Lists.pptx
Data Structures_Linear data structures Linked Lists.pptxData Structures_Linear data structures Linked Lists.pptx
Data Structures_Linear data structures Linked Lists.pptx
RushaliDeshmukh2
 
ADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITY
ADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITYADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITY
ADVXAI IN MALWARE ANALYSIS FRAMEWORK: BALANCING EXPLAINABILITY WITH SECURITY
ijscai
 
Compiler Design_Lexical Analysis phase.pptx
Compiler Design_Lexical Analysis phase.pptxCompiler Design_Lexical Analysis phase.pptx
Compiler Design_Lexical Analysis phase.pptx
RushaliDeshmukh2
 
Metal alkyne complexes.pptx in chemistry
Metal alkyne complexes.pptx in chemistryMetal alkyne complexes.pptx in chemistry
Metal alkyne complexes.pptx in chemistry
mee23nu
 
DSP and MV the Color image processing.ppt
DSP and MV the  Color image processing.pptDSP and MV the  Color image processing.ppt
DSP and MV the Color image processing.ppt
HafizAhamed8
 
LECTURE-16 EARTHEN DAM - II.pptx it's uses
LECTURE-16 EARTHEN DAM - II.pptx it's usesLECTURE-16 EARTHEN DAM - II.pptx it's uses
LECTURE-16 EARTHEN DAM - II.pptx it's uses
CLokeshBehera123
 

Buttons In .net Visual Basic

  • 1. FEDT Presentation GGS INDRAPRASTH UNIVERSITY Submitted to Submitted MANISH BCA E1 2016-2019
  • 3. VISUAL BASIC INTERFACE When we write a Visual Basic program, you first have to design the user interface. Essentially, a Visual Basic user interface consists of objects that you place on the screen. The common elements of a Visual Basic user interface consist of the following: •Forms (also known as windows) •Buttons (such as command buttons and radio buttons) •Boxes (such as text boxes and check boxes) •Labels •Pictures (such as icons and graphics)
  • 4. BUTTON The button control is your standard GUI function, usually used to confirm something or trigger an event. Such uses for a button include search engine's, dialog boxes, message boxes, etc. They are usually used to give the user an option or choice. Button can be clicked by a mouse click or by pressing ENTER or ESC keys.
  • 5. CREATING A BUTTON BY DRAG & DROP To create a Button control, you simply drag and drop a Button control from Toolbox to Form in Visual Studio.
  • 6. CREATING A BUTTON AT RUN-TIME VB.Net allow us to add button at run time by typing code:- Dim button1 as new button Me.Controls.Add(button1)
  • 7. PROPERTIES OF THE BUTTON CONTROL 1 AutoSizeMode Gets or sets the mode by which the Button automatically resizes itself. 2 BackColor Gets or sets the background color of the control. 3 BackgroundImage Gets or sets the background image displayed in the control. 4 DialogResult Gets or sets a value that is returned to the parent form when the button is clicked. This is used while creating dialog boxes. 5 ForeColor Gets or sets the foreground color of the control. 6 Image Gets or sets the image that is displayed on a button control. 7 Location Gets or sets the coordinates of the upper- left corner of the control relative to the upper-left corner of its container. 8 TabIndex Gets or sets the tab order of the control within its container. 9 Text Gets or sets the text associated with this control.
  • 8. WORKING OF BUTTON When we click the button a handler is executed. Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click After it we can give instructions that will be done after the button click. Button sub is End by using End sub
  • 10. CODE Public Class Form1 Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim a As Integer = TextBox1.Text If a Mod 2 = 0 Then MsgBox("No is even") Else MsgBox("No is odd") End If End Sub End Class Statement that will be executed after button click