HI People, Am new to programming basic, and have been working on a calc. to work out the storage requirements of a bitmap graphic in MB using the inputs Height, Breadth, Resolution and Colour depth has been driving me mad as when i run the programme nothing happens, even the clear data button is non functional, was wondering if any could help pls.

9 Years
Discussion Span
Last Post by claysteven


Private Sub cmdCalculate_Click()
'Code for the Calculate Command Button
'By Steven Clay

Dim Resolution As Integer
Dim Height As Integer
Dim Breadth As Integer
Dim Colour_Depth As Integer
Dim Total_Number_of_Pixels As Integer
Dim Result As Integer

Resolution = txtResolution.Text
Height = txtHeight.Text
Breadth = txtBreadth.Text
Colour_Depth = txtColour_Depth.Text

Total_Number_of_Pixels = (Breadth * Resolution) * (Height * Resolution)

End Sub

Private Sub cmdClearClick()
'clears all the text boxes

txtResolution.Text = ""
txtHeight.Text = ""
txtBreadth.Text = ""
txtStorage.Text = ""
txtColour_Depth.Text = ""
txtTotal_Number_of_Pixels = ""

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.