So i got a form with a bunch of buttons on it that do calculations of various natues (simple ones)...I typed my actual calculation codes using function in a module. For instance
Function Meter(ByVal Temp As Integer) As Integer
Temp = Temp / (3.2808)
Return Temp
End Function
That is one example of a function in my module....But when i call it in button procedure.....
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
TextBox2.Text = Format(Meter(TextBox1.Text), "Fixed")
Label1.Text = "Feet"
Label2.Text = "Meters"
It does NOT return a decimal for some reason....and yes instead of "fixed" i have tried ###.## and 000.00.....how can i get this sucker to return an actual decimal?
Function Meter(ByVal Temp As Integer) As Integer
Temp = Temp / (3.2808)
Return Temp
End Function
That is one example of a function in my module....But when i call it in button procedure.....
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
TextBox2.Text = Format(Meter(TextBox1.Text), "Fixed")
Label1.Text = "Feet"
Label2.Text = "Meters"
It does NOT return a decimal for some reason....and yes instead of "fixed" i have tried ###.## and 000.00.....how can i get this sucker to return an actual decimal?