Open topic with navigation
WR_SemOpen
This function can be used to open a Network Semaphore File in exclusive mode in order to count the number of concurrent network users.
Network Floating Licensing is no longer supported. If network licensing is required, the Protection PLUS 5 SDK supports network licensing capabilities.
Syntax
- Visual Basic
- Declare Function WR_SemOpen(ByVal flags As Long,
ByVal prefix_server As String,
ByVal name As String,
ByRef sem_handle As Long)
As Long
- C/C++:
- LONG WR_SemOpen(LONG flags,
LPSTR prefix_server,
LPSTR name,
LPPPLFHANDLE sem_handle);
Arguments
- flags
- Reserved. Set to 0
- prefix_server
- The complete path, including a trailing backslash, to the Network Semaphore Files of the server counting the number of concurrent users.
- name
- A four-character identifier to use to count the users.
- sem_handle
- A pointer in which to place the Network Semaphore File handle.
Returns
If the call fails, any of the API Error Codes may be returned.
- -2
- The application has not been wrapped.
- -1
- The API is not available. Please check your wizard settings. See the Testing section in the API Setup topic for more information.
- 1
- The Network Semaphore File was successfully opened.