One thing that jumps to mind is to build a table with 1 column. In the column have a "counter". By counter, have a number that you can increment each time the form is opened.
When that number is reached, have the module executed.
Kinda like:
if intCounter = 5 then
blah blah
else
increment counter +1
end if
you could add this check to the the onOpen event. oh, dont forget to reset your counter after 5 has been reached.
Correct a table is the only approach. Although, I would use the user table that contains the user login info and store the counter for each successful login. The data check could also be based on values stored in the user table. So, add two fields to user table is my 2 cents. One field for Login Counter and Another for Last Login Date. When login code is triggered, make sure you reset the values in the table whereas counter will be zero and last login date is today. htwhm,
Steve Medvid
"IT Consultant & Web Master"
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.