This
I need the source code and design for the form.
Please complete this in Visual Basic .NET
Below is the solution:
create textbook for member no. and no of movies for input and display the calculated value in rental groupbox and summary groupbox
code:
Public Class frmVideoBonanza
Const VidPrice As Decimal = 1.8
Public numberofcustomers As Integer
Public totalamt As Decimal
Private Sub frmVideoBonanza_Load(sender As
Object, e As EventArgs) Handles MyBase.Load
MemberTextBox.Select()
'focus on textbox on form load
'disable all the result
textbox
RentalTextBox.Enabled =
False
DiscountTextBox.Enabled
= False
AmountTextBox.Enabled =
False
TotalRentIncomeTextBox.Enabled = False
NumOfCustServTextBox.Enabled = False
End Sub
Private Sub btnExit_Click(sender As Object, e
As EventArgs) Handles btnExit.Click
Me.Close() 'close
application
End Sub
Private Sub btnPrint_Click(sender As Object,
e As EventArgs) Handles btnPrint.Click
'print Form
PrintForm1.PrintAction =
Printing.PrintAction.PrintToPreview
PrintForm1.Print()
End Sub
Private Sub btnClear_Click(sender As Object,
e As EventArgs) Handles btnClear.Click
'clear the all
TextBox
NumberOfVidsTextBox.Clear()
RentalTextBox.Clear()
DiscountTextBox.Clear()
AmountTextBox.Clear()
TotalRentIncomeTextBox.Clear()
NumOfCustServTextBox.Clear()
With MemberTextBox
.Clear()
.Focus()
End With
End Sub
Private Sub btnCalculate_Click(sender As
Object, e As EventArgs) Handles btnCalculate.Click
'calculate and display
the rental amount
'declaring
variable
Dim rental As
Decimal
Dim Amount As
Decimal
Dim numberofVids As
Decimal
Dim Discount As Decimal
= 0.1 '10% discount
'start the if
statement to make sure a member number is entered.
'(usernumber must be at
least 4 digits.)
If
MemberTextBox.TextLength > 1 Then
'start the try statement to catch no videos rented error.
Try
'calculate the rental amount, the discount and the amount due
numberofVids = Decimal.Parse(NumberOfVidsTextBox.Text)
rental = numberofVids * VidPrice
Discount = rental * Discount
Amount = rental - Discount
'calculate totals for all customers
numberofcustomers = numberofcustomers + 1
totalamt = Amount + totalamt
'display the results in textbox
NumOfCustServTextBox.Text = numberofcustomers
RentalTextBox.Text = rental.ToString("C")
DiscountTextBox.Text = Discount.ToString("C")
AmountTextBox.Text = Amount.ToString("C")
TotalRentIncomeTextBox.Text = totalamt.ToString("C")
'end of try, if was error show the message
Catch ex As FormatException
MessageBox.Show("Error; No videos rented", "Error",
MessageBoxButtons.OK, MessageBoxIcon.Error)
End Try
'end of try, if was error show the message
Else
MessageBox.Show("Error; no member number entered, make sure you
entered 4 digits", "Error", MessageBoxButtons.OK,
MessageBoxIcon.Error)
End If
End Sub
End Class
output:
This I need the source code and design for the form. Please complete this in Visual...
Hi can I please the code and test bench in VHDL code One design source for the 4-bit adder/subtractor One testbench to test the 4-bit adder/subtractor
VISUAL BASIC (VISUAL STUDIO 2010) - PLEASE INCLUDE PICTURES OF OUTPUT AND CODE AND TEXTBOX pictures of everything or thumbs downnnnnnn... Your question has been answered Let us know if you got a helpful answer. Rate this answer Question: VISUAL BASIC (VISUAL STUDIO 2010) - PLEASE INCLUDE PICTURES OF OUTPUT AND CODE AND TEXTBOX Be sur... VISUAL BASIC (VISUAL STUDIO 2010) - PLEASE INCLUDE PICTURES OF OUTPUT AND CODE AND TEXTBOX Be sure to include comments at the top of...
PLEASE DO IN C# AND MAKE SURE I CAN COPY CODE IN VISUAL STUDIO Program 2: Design (pseudocode) and implement (source code) a class called Counter. It should have one private instance variable representing the value of the counter. It should have two instance methods: increment() which adds on to the counter value and getValue() which returns the current value. After creating the Counter class, create a program that simulates tossing a coin 100 times using two Counter objects (Head...
Visual Basic - I need to make a program to search a text file that is in the debug. Found from "IO.File.ReadAllLines". When the word is typed into a textbox and button pressed, the program should show which line the word first appeared in the text through a message box or another feature. If it is not found, the program will open a message box. I don't have the full code, please assist
C++ Please complete the implementation of the following source code (Question3.cpp). You need to add your code in the source code where the comment “// your code” locates. After you finish the implementation, please also provide the output of your program. #include <iostream> using namespace std; class Shape { protected: // your code public: void setWidth (int w) { // your code } void setHeight (int h) { // your code } }; class Rectangle: public Shape { public: int...
I really need some help fixing a code error in Visual Basic I was wondering if anyone could help fix the error that I'm about to provide in bold thanks so much! I'll also tell what the error is. Public Class MainForm Private Sub exitButton_Click(sender As Object, e As EventArgs) Handles exitButton.Click Me.Close() End Sub Dim img As Image = Image.FromFile("C:\Users\Pranesh\Pictures\11599264.jpg") house1PictureBox.Image = img house2PictureBox.Image = img house3PictureBox.Image = img house4PictureBox.Image = img house1PictureBox.Visible = False house2PictureBox.Visible = False house3PictureBox.Visible...
PLEASE DO IN C# AND MAKE SURE I CAN COPY CODE IN VISUAL STUDIO Program 2: Design (pseudocode) and implement (source code) a program (name it FeetMeters) to display a conversion tables for feet and meter as show below. Document your code and properly. Feet Meter 1.0 0.305 2.0 0.610 3.0 0.915 . . . . . . 19.0 5.7.95 20.0 6.100 Meter Feet 1.0 3.279 2.0 6.558 3.0 9.837 . . . . . . 19.0 62.301 20.0 65.574...
Please help with this visual basic code. If they are, indicate in which order the array elements will be processed. Give reasons for the ones that are not correct. For j As Integer = 1 To intMAXCOL strBoard(j,i) = "*" For j As Integer = 1 To intMAXCOL strBoard(j,i) = "*"
Using Visual Basic Design the appropriate window and write the necessary code to enter the value of x and calculate the value of Y From the following equationس2/ باستخدام لغة فيجوال بيسك صمم النافذة المناسبة وأكتب التعليمات البرمجية اللازمة لأدخال قيمة x وحساب قيمة Y من المعادلة التالية : 비건 29log(x) + Y =
please help me finish this, it is for Visual Basic . net in Visual studio 2010 (show pictures of code and of the form please) Lab #5 - Banking Account with Methods Submit Assignment Download Work file Download Runtime Be sure to include comments at the top of each procedure and at the top of the file. Be sure to use meaningful names for all buttons and labels. In this lab you will create a simple banking application that will...