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 strongm 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. ramzoid

    validation error despite cancel in beforeupdate

    I get it! In the form properties, for the On Error event, I put the MsgBox DataErr line, and this gives me the error number. Then I add the other code with the error number plugged in, and it kills that particular error message. Excellent! It works. (I still don't know why I was getting the...
  2. ramzoid

    validation error despite cancel in beforeupdate

    As far as I can tell, there is no actual "validation rule" per se, neither on the text box on the form, nor on the underlying fields in the table. I have been assuming that the validation error comes from the code for the BeforeUpdate event; I don't really know, though, if Access considers this...
  3. ramzoid

    validation error despite cancel in beforeupdate

    OK. I think you'll see there's not any real difference in format between passing and failing barcodes; it's just a matter of whether that particular number is in the database. Pass: 9969, 97300, 129310 Fail: 9970, 97301, 129410 "The value in the field or record violates the validation rule...
  4. ramzoid

    validation error despite cancel in beforeupdate

    So, I'm thinking through this a little more... The "If" statement with the Dcount function appears to be working OK, because when the barcode entered does exist in the table "barcode name", the sub ends as it should, and when the entered barcode does not match, I do in fact get the desired...
  5. ramzoid

    validation error despite cancel in beforeupdate

    AceMan, A very reasonable guess (thanks!), but it doesn't appear that that was the problem. I got a data type mismatch when I tried it. Thanks though! Any other hunches? Cheers!
  6. ramzoid

    validation error despite cancel in beforeupdate

    I have a data-entry form with one bound text field to receive a number from a barcode scanner. The BeforeUpdate event for this field contains code to verify that the ID number scanned is valid: Private Sub barcode_BeforeUpdate(Cancel As Integer) If DCount("*", "barcode name", "barcode=" &...
  7. ramzoid

    Calculated text box and variables

    Thanks! The suggestion you posted to the related thread, of just setting the name of the ubound box equal to the dlookup expression (in the sub for the data-entry box) works perfectly! Thanks for addressing all the sub-questions! Joe
  8. ramzoid

    display confirmation of input in data entry form

    So simple! I didn't know you could put content into a text box using the same syntax as storing a value in a variable. Beautiful! It works perfectly. Thanks!!! Joe
  9. ramzoid

    Calculated text box and variables

    I am trying to use an unbound text box to display a message based on the contents of a data-entry text box. In the sub associated with the data-entry box, the message text is stored in a string variable, sMessage. I tried simply putting =[sMessage] in the control source for the unbound box...
  10. ramzoid

    display confirmation of input in data entry form

    OK, so I think I understand Sarah's code, and it works like a charm (thanks again!), but I still have a problem. I would like for the users to be able to check in & out using the barcode scanner only (no mouse, no keyboard), so the Msgbox doesn't quite do it, since users must click OK before...
  11. ramzoid

    display confirmation of input in data entry form

    Sarah, This looks extremely promising! I'll have to wrestle with it a bit before I really understand the code, but it looks great. I did not know about the Msgbox function; that seems like a much better way to go than using a subform. I will see if I can get this working and report back...
  12. ramzoid

    display confirmation of input in data entry form

    Warning: question from a beginner Context: A user with a barcoded ID card will use a simple data-entry form to "clock in" and "clock out" their arrival/departure by scanning their barcode. Problem: I want to give the user visual confirmation of their input; specifically, the user will enter a...

Part and Inventory Search

Back
Top