force data entry in user form

p4nny

Board Regular
Joined
Jan 13, 2015
Messages
246
Hi

I would like to force data entry in an access userform before moving on to next record.. This is made up of mutiple textboxes and comboboxes

thanks in advance
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
If your question is about converting the Form into a Data Entry Form then change the Data Entry property value to Yes.

If your question is about forcing the User to enter data into the fields before moving to the next record then change the Input Mask property value of all the Text Box to appropriate character (A or L etc.). See the Input Mask characters given below:

CharacterDescription
0Digit (0 to 9, entry required, plus [+] and minus [–] signs not allowed).
9Digit or space (entry not required, plus and minus signs not allowed).
#Digit or space (entry not required; spaces are displayed as blanks while in Edit mode, but blanks are removed when data is saved; plus and minus signs allowed).
LLetter (A to Z, entry required).
?Letter (A to Z, entry optional).
ALetter or digit (entry required).
aLetter or digit (entry optional).
&Any character or a space (entry required).
CAny character or a space (entry optional).
. , : ; - /Decimal placeholder and thousand, date, and time separators . (The actual character used depends on the settings in the Regional Settings Properties dialog box in Windows Control Panel).
<Causes all characters to be converted to lowercase.
>Causes all characters to be converted to uppercase.
!Causes the input mask to display from right to left, rather than from left to right. Characters typed into the mask always fill it from left to right. You can include the exclamation point anywhere in the input mask.
\Causes the character that follows to be displayed as the literal character (for example, \A is displayed as just A).

Above information taken from Microsoft Access help document.

<tbody>
</tbody>
 
Upvote 0
Very nice posts.Thank you so much.

I will used that this userform for text box next i will be go to next new entry of form.If it's better the to do this fields.
 
Upvote 0
p4nny,

FYI: User Forms are in Word and Excel not Access. Access forms are usually bound to a table.


Input mask so not make a file required.

Three are several thint that need to be done to handle. this.

1) in the table design set the field's required property to Yes.
2) In the form's before Update event add validation code to give the user a better indication to what is missing.


Setting the Data Entry property value to Yes for a form only tells Access not to show existing records int he recordset. I almost never use set this to yes.
 
Upvote 0

Forum statistics

Threads
1,213,504
Messages
6,114,020
Members
448,543
Latest member
MartinLarkin

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top