DaveC426913
Programmer
I've got a list of clients in a table, with the number of licenses they're allowed to have and the number of licenses currently in use. I don't need to assign a unique license to a user, just as long as I ensure that there are not more users than licences allowed.
As soon as a new user starts the registration process, I need to increment the 'Licenses used' field, otherwise I might have collisions (such as two users vying for one remaining license). If that user fails to complete the registration process, I'll decrement the counter again, to make it available for the next user.
Here's my problem: since this is a web form, the user could, upon failing the registration, simply close his browser. Thus there is no "place" for me to know that they've failed. That counter has no reason to get decrmented.
I suppose I could time it, but that's so inelegant and over-engineered. More to the point, it is not user-transparent.
As soon as a new user starts the registration process, I need to increment the 'Licenses used' field, otherwise I might have collisions (such as two users vying for one remaining license). If that user fails to complete the registration process, I'll decrement the counter again, to make it available for the next user.
Here's my problem: since this is a web form, the user could, upon failing the registration, simply close his browser. Thus there is no "place" for me to know that they've failed. That counter has no reason to get decrmented.
I suppose I could time it, but that's so inelegant and over-engineered. More to the point, it is not user-transparent.