AIDA_hCreateStackEx

The AIDA_hCreateStackEx function creates a new AIDA stack.

handle AIDA_hCreateStackEx(
  dword dwCreateOptions
);

Parameters

dwCreateOptions
A flag field describing the options to be used for stack creation. Possible values are:

AIDA_nStackCreateRestoreNormal
AIDA_nStackUnmanagedIdMode
AIDA_nStackForcedOffline

AIDA_nStackCreateRestoreNormal is used when no other flag is needed.

AIDA_nStackUnmanagedIdMode must be set when the event id manager shall not be used.

AIDA_nStackForcedOffline must be set when the stack shall be forced offline after creation.

Return Values

AIDA_hCreateStackEx returns a handle for the created AIDA stack.

If the function fails, the return value is NULL. The application can retrieve the error code using AIDA_iGetError.

Remarks

The returned handle has to be treated as opaque value.

Example

/* CREATESTACKEX.C: This program creates an AIDA
 * stack and deletes it afterwards.
 */

#include <stdio.h>
#include <errno.h>
#include "bsk_aida.h";

void main( void )
{
  handle hStack;

  /* Create a stack */
  hStack = AIDA_hCreateStackEx(AIDA_nStackForcedOffline | AIDA_nStackUnmanagedIdMode);
  if( hStack == NULL )
    printf( "Error creating stack: %d\n", AIDA_iGetError() );
  else
  {
    printf( "Stack created.\n" );
    if( !AIDA_boDeleteStack( hStack ) )
      printf( "Error deleting stack: %d!\n", AIDA_iGetError );
    else
      printf( "Stack deleted.\n" );
  }
}

Output

Stack created
Stack deleted

QuickInfo

  Windows NT: Requires version 3.1 or later.
  Windows: Requires Windows 95 or later.
  Linux: Requires a kernel supporting ELF binaries.
  Header: Declared in bsk_aida.h, also requires portab.h.
  Import Library (Windows): Use BSK_AIDA.lib.

See Also

AIDA Overview, AIDA Stacks Licensing/Authentication Overview, AIDA Functions, AIDA_hCreateStack, AIDA_boDeleteStack, AIDA_boSaveStack, AIDA_hRestoreStack, AIDA_hRestoreStackRaw, AIDA_hRestoreStackEx, AIDA_pastSetReplacementTable, AIDA_bAddToStack, AIDA_boRemoveFromStack, AIDA_xsComponentName