Roger's Access Library Homepage
Forum Home Forum Home > Other Download Libraries > Access-L Developer's Libraries > Squires, Neil
  New Posts New Posts RSS Feed - Semaphore.mdb
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Please consider donating $1 per sample downloaded, (find out why here)


 Post Reply Post Reply
Neil Squires View Drop Down

Joined: 30 Jun 2008
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Neil Squires Quote  Post ReplyReply Direct Link To This Post Topic: Semaphore.mdb
    Posted: 10 Jul 2008 at 3:01am
I developed this solution because on several lists I'm on, there are questions 
each week about clients wanting autonumbers displayed and they get upset when
there are gaps.  They are expecting sequential numbers, and the autonumber 
datatype doesn't quite match what they are looking for.  

This program will allow the developer to get the next number increment. They may 
request either (Max+1), or fill in missing numbers first, then get (Max+1).  The code 
should work in a muti-user environment.  It uses semaphore logic to prevent 2 users
from retrieving the same number at the same time.  

Note: This new functionality is not meant to superscede the autonumber datatype.  
You should still use autonumber for relational integrity, but if the user wants a 
number to see, this is a solution worth looking at. 

Access Version: 2000 and probably newer.
   Microsoft ActiveX Data Objects 2.1 Library
   Microsoft ADO Ext. 2.7 for DDL and Security

Download Access 2000+ : uploads/35/


I only ask that the comments be left intact in the code module. Otherwise, it's for use freely by whoever.
Back to Top
Sponsored Links

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.03
Copyright ©2001-2019 Web Wiz Ltd.