Example for Extracting Security

The following example extracts role access definitions and security class access definitions from an application.

Dim cSecurityLoadACV As HsvSecurityLoadACV
Dim cOptions As IHsvLoadExtractOptions
Dim cOpt As IHsvLoadExtractOption
Set cSecurityLoadACV = New HsvSecurityLoadACV
'Specify the HsvSession object for the application.
cSecurityLoadACV.SetSession g_cHsvSession
'Initialize the IHsvLoadExtractOptions interface.
Set cOptions = cSecurityLoadACV.ExtractOptions
Set cOpt = cOptions.Item(HSV_SECURITYEXTRACT_OPT_SECURITY_CLASSES)
cOpt.CurrentValue = False
Set cOpt = cOptions.Item(HSV_SECURITYEXTRACT_OPT_USERS)
cOpt.CurrentValue = False
cSecurityLoadACV.Extract "c:\Acme\SecurityAccess.sec", _
  "c:\Acme\SecurityAccess.log"