Showing posts with label absolute value in vb. Show all posts
Showing posts with label absolute value in vb. Show all posts

Friday, October 7, 2016

Absolute Value Solver in Visual Basic

A simple program that I wrote using Microsoft Visual Basic 5 to solve the absolute value of the given negative integer number by the user. The code is very simple and easy to understand.

Add me at Facebook my address is jakerpomperada@gmail.com and jakerpomperada@yahoo.com. 


My email address are the following 
jakerpomperada@gmail.com and jakerpomperada@yahoo.com. 

My mobile number here in the Philippines is 09173084360.




Sample Program Output



Program Listing

Private Sub Command1_Click()
Dim value_a As Integer

value_a = Abs(Val(Text1.Text))

Label3.Caption = "The absolute value of " & Text1.Text & _
                 " is " & value_a & "."
End Sub


Private Sub Command2_Click()
Text1.Text = ""
Text1.SetFocus
End Sub