Hi guys
I'm having some trouble with a database I'm building. I have a form named frmNewPhys that has a text box to input a new physician name into the database, and a button linked to a macro that saves it, updates the physician table, and closes the window.
I'm trying to figure out how I can pop up an error window if someone tries to save with no data in the text box.
I had edited the save button macro to pop up an error form I created. The first line in the macro said "onError" go to next step, where the next step was to open the error form. That seems to work, but the error form still pops up even if data is present in the text box.
I thought an if/else statement would work, but I have no idea how to do this in access. Any help is appreciated.
DB info:
Physician entry form name - 'NewPhysician'
Physician table name - 'Physicians'
Field name in table - 'Physician'
I'm having some trouble with a database I'm building. I have a form named frmNewPhys that has a text box to input a new physician name into the database, and a button linked to a macro that saves it, updates the physician table, and closes the window.
I'm trying to figure out how I can pop up an error window if someone tries to save with no data in the text box.
I had edited the save button macro to pop up an error form I created. The first line in the macro said "onError" go to next step, where the next step was to open the error form. That seems to work, but the error form still pops up even if data is present in the text box.
I thought an if/else statement would work, but I have no idea how to do this in access. Any help is appreciated.
DB info:
Physician entry form name - 'NewPhysician'
Physician table name - 'Physicians'
Field name in table - 'Physician'