Hello everyone-
I have a form in Access. On that form there is a subform. The view of this subform is set to 'Datasheet'. So it lists all of the contents as separate rows in this subform, not unlike an excel spreadsheet would look. Then you can type into the bottom line and it will add a new entry into the list of items. All I want to be able to do is control what data goes into the new record. So when a user enters in "1234" into the first column and then tabs into the second column, I want the program to be able to show a pop up "1234 is not a valid entry", and then put the focus back into the first column.
I just can't find where to put this code, or under what event. I've tried the AfterUpdate, Change, and LostFocus event fields, and no matter what I can't get it to work.
Hopefully that made sense. Let me know if you have any ideas, or if you need any more details.
Thanks
-Mark
I have a form in Access. On that form there is a subform. The view of this subform is set to 'Datasheet'. So it lists all of the contents as separate rows in this subform, not unlike an excel spreadsheet would look. Then you can type into the bottom line and it will add a new entry into the list of items. All I want to be able to do is control what data goes into the new record. So when a user enters in "1234" into the first column and then tabs into the second column, I want the program to be able to show a pop up "1234 is not a valid entry", and then put the focus back into the first column.
I just can't find where to put this code, or under what event. I've tried the AfterUpdate, Change, and LostFocus event fields, and no matter what I can't get it to work.
Hopefully that made sense. Let me know if you have any ideas, or if you need any more details.
Thanks
-Mark