Please, read my comment to the question...
If you use sql server, you can save information about number of connections made to the server when application starts and delete such of information when application quits.
A table used to store loged in/out machines might look like (pseudo-SQL):
AppLogs
(
NOLId -- Primary key
MachineIP -- machine IP
LogInTime -- Log in date and time
LogOutTime -- Log out date and time
)
Example query to check no. of loged machines:
SELECT COUNT(*)
FROM AppLogs
WHERE LogInTime = @currentDate AND LogOutTime IS NULL
Got an idea?