|  |   |   | 
version 2003
PA_LockResourceHandle (resfile; rHandle)
| Parameter | Type | Description | |
| resfile | short | → | File reference number of the file to access | 
| rHandle | PA_Handle | → | Handle to the resource to lock | 
Description
   The routine
   
    
     PA_LockResourceHandle
    
   
   locks the resource handle
   
    rHandle
   
   . After the call, the handle cannot be purged, released or resized.
   
    rHandle
   
   references a resource of the file
   
    resFile
   
   .
  
   In addition, the resource's "locked"  attribute is saved, even after the file has been closed.  At the next opening, the resource will be locked until the plug-in calls
   
    
     PA_UnlockResourceHandle
    
   
   .
  
   Please note that
   
    
     PA_LockresourceHandle
    
   
   has a very different effect than
   
    
     PA_LockResource
    
   
   .
   
    
     PA_LockResource
    
   
   locks the resource over the network so that no one can modify it, it does not concern the handle of the resource.
  
Example
We do not want a resource to be modified.
   PA_Handle   h;
   h = PA_GetResourceHandle(resFile, 'xxxx', 128);
   if(h)
      PA_LockResourceHandle(resFile, h);
See Also
About the internal resource manager , PA_GetResourceHandle , PA_LockResource , PA_UnlockResourceHandle .
Error Handling
   Use
   
    
     PA_GetLastError
    
   
   to see if an error occurred