Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. RoccoSiffredi

    MessageBox.Show on no input in Label?

    Can someone recommend a VBA book or resource listing commands and their parameters?
  2. RoccoSiffredi

    MessageBox.Show on no input in Label?

    Yep that did it. The issue was I had this after my dims : days = txtdays.Text months = months.Text years = text.Text In order to add the three values together. I moved them after the validation and it worked. Thank you very much. Can you explain what 'Val' does? Haven't come across this...
  3. RoccoSiffredi

    MessageBox.Show on no input in Label?

    Actually it doesn't work, it produces errors even if the value entered is below 100.
  4. RoccoSiffredi

    MessageBox.Show on no input in Label?

    Thanks Andy. I created a new form with your code and it works. What I want to do is give errors if : There is no input There is not a numerical input The value entered is over 100 For some reason this works but I don't understand why : If Not (IsNumeric(txtdays.Text) > 100) Or txtdays.Text =...
  5. RoccoSiffredi

    MessageBox.Show on no input in Label?

    Thanks but it sill hangs.
  6. RoccoSiffredi

    MessageBox.Show on no input in Label?

    I want the messagebox.show to display an error message if there is no input in a label : If (txtdays.Text > 100) And (txtdays.Text = "") Then MessageBox.Show("Please enter a value between 1 and 100") There are no errors in the code but if there is no input in the txtdays label VBE hangs. What...
  7. RoccoSiffredi

    VBA Crashing On Validation Even With No Errors

    I have vba to compare values entered in a textbox. The code validates (Visual Basic 2010 Express) but hangs when I run it and enter a non numerical value in the TxtInputDays box. If Not (IsNumeric(TxtInputDays)) Then MessageBox.Show("Please enter a numerical value") ElseIf result1 >...
  8. RoccoSiffredi

    Stringing Together Multiple Ifs & Displaying Calculations To 2 DPs

    Thanks. That worked! Dim twodec As Decimal twodec = Format(Amount, "0.00") mcubed.Text = "The Parcel in square metres is " & twodec.ToString
  9. RoccoSiffredi

    Stringing Together Multiple Ifs & Displaying Calculations To 2 DPs

    I have defined the value as a decimal. I don't understand the syntax to round a caculation to 2dp.
  10. RoccoSiffredi

    Stringing Together Multiple Ifs & Displaying Calculations To 2 DPs

    Thanks for the solutions. Still need help with the decimal places problem.
  11. RoccoSiffredi

    Stringing Together Multiple Ifs & Displaying Calculations To 2 DPs

    sorry width not weight, to calculate cubic feet. That's not important, nesting the statements is the issue.
  12. RoccoSiffredi

    Stringing Together Multiple Ifs & Displaying Calculations To 2 DPs

    I've created vba to calculate the area of a parcel. There are two valdiation checks : If the parcels weight is less than or equal to 25 If the parcels height is less than or equal to 100 Then the formula to calculate the area is run otherwise error messages are displayed in message boxes...
  13. RoccoSiffredi

    VBA Crashing if User Does not Enter Value In Box

    Hi All The following VBA adds an integer to another integer, if a value is entered in the textbox. If the user does not enter a value in the box i.e. it is left blank and the User Change button is clicked the VBA freezes - I'm using Visual Basic Express. What statement do I need to enter to...

Part and Inventory Search

Back
Top