![EBK 3N3-EBK: PROGRAMMING W/MICROSOFT VI](https://www.bartleby.com/isbn_cover_images/9780176920159/9780176920159_largeCoverImage.gif)
Explanation of Solution
Program
Public Class frmMain
'declaring variables of string type
Dim capital As String
Dim state As String
'display button click
Private Sub btnDisplay_Click(sender As Object, e As EventArgs) Handles btnDisplay.Click
'display state and capital on label
lblCapital.Text = String.Format(" State : {0} , Capital is : {1}", state, capital)
'change forecolor of label
lblCapital.ForeColor = Color.Maroon
'change backcolor of label
lblCapital.BackColor = Color.Yellow
End Sub
'Exit button click
Private Sub btnExit_Click(sender As Object, e As EventArgs) Handles btnExit.Click
'when this button clicked close the application
Application.Exit()
End Sub
'checkChanged event for radio button texas
Private Sub rbtTaxas_CheckedChanged(sender As Object, e As EventArgs) Handles rbtTaxas.CheckedChanged
'clear text on label
lblCapital.Text = ""
'if radio button texas is checked
If rbtTaxas.Checked = True Then
'set the value of variable capital
capital = "Austin"
'set the state name as radio button text
state = rbtTaxas.Text
End If
End Sub
'checkChanged event for radio button washington
Private Sub rbtWashington_CheckedChanged(sender As Object, e As EventArgs) Handles rbtWashington.CheckedChanged
'clear text on label
lblCapital.Text = ""
'if radio button washington is checked
If rbtWashington.Checked = True Then
'set the value of variable capital
capital = "Olympia"
'set the state name as radio button text
state = rbtWashington...
![Check Mark](/static/check-mark.png)
Trending nowThis is a popular solution!
![Blurred answer](/static/blurred-answer.jpg)
Chapter 4 Solutions
EBK 3N3-EBK: PROGRAMMING W/MICROSOFT VI
- Which property is used to give a form file a more meaningful name? File File Name Form Name Namearrow_forwardThis is for Visual Basic I and is not in a textbook. Create a Windows Form application. Use the following names for the project and solution, respectively: NFL Teams Project and NFL Teams Solution. Add any 6 NFL teams to a list box. When the user clicks a team in the list box, the list box’s SelectedIndexChanged procedure should display the State that the NFL Team is from in a label control. Example "Altanta Falcons" display Georgia, in the label. Look back at Chapter 5 for examples of list boxes. I need some help understanding it. My teacher gave this to me as a example question.arrow_forwardInclude a header that is Your Name, Math Tables Include an "Addition Table" button Include a "Multiplication Table" button Both tables should use the same window for the display of their information In the secondary window, include the following: A comment in the code that includes the assignment name, your name, and the date Use the file name "MathTableDisplay.htm" for the secondary window file The header for the secondary window is "Addition Table" when the addition table is displayed The header for the secondary window is "Multiplication Table" when the multiplication table is displayed Example web page displays and code for the addition table are included belowarrow_forward
- Programming with Microsoft Visual Basic 2017Computer ScienceISBN:9781337102124Author:Diane ZakPublisher:Cengage Learning
![Text book image](https://www.bartleby.com/isbn_cover_images/9781337102124/9781337102124_smallCoverImage.gif)