EsbGetDatabaseState

Gets a database's state structure, which contains user-configurable parameters for the database.

Syntax

EsbGetDatabaseState (hCtx, AppName, DbName, pDbState)
ByVal hCtx     As Long
ByVal AppName  As String
ByVal DbName   As String
      pDbState As ESB_DBSTATE_T
ParameterDescription

hCtx

VB API context handle.

AppName

Application name.

DbName

Database name.

pDbState

Buffer to receive a database state structure.

Notes

This function can get only a server database's state structure.

Return Value

If successful, this function returns a pointer to a database state structure in pDbState.

Access

To get a database's state structure, the connected user must have at least read access (ESB_PRIV_READ) to the database.

Example

Declare Function EsbGetDatabaseState Lib "ESBAPIN" (ByVal hCtx As Long, ByVal AppName As String, ByVal DbName As String, pDbState As ESB_DBSTATE_T) As Long 

Sub ESB_GetDatabaseState()
   Dim sts As Long
   Dim AppName As String
   Dim DbName As String
   Dim DbState As ESB_DBSTATE_T   AppName = "Sample"
   DbName = "Basic"   '******************************** 
   '****** Get Database State ******
   '********************************
   sts = EsbGetDatabaseState(hCtx, AppName, DbName,
   DbState)
End Sub

See Also