• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 465
  • Last Modified:

Check if all fields in new row are filled (datasheet view)

Hi there

I have a form with datasheet view and I need to make user that user fills in all fields before he moves on to the next row.
Any idea how to catch the moment of moving to another row?
0
yahooooo
Asked:
yahooooo
1 Solution
 
mbizupCommented:
Use the Before Update event of your form.


Private Sub Before_Update(Cancel as Integer)
       if "" & Me.Field1 = ""  OR  "" & Me.Field2 = "" OR "" & Me.Field3 = ""  OR "" & Me.Field4 = "" then
               msgBox "Please enter data in all fields"
               Cancel = True
        end if
end sub

Open in new window

0

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now