gtpc2m0gC/C++ Language Support User's Guide

attac-Attach a Detached Working Storage Block

The attac function reattaches a working storage block to an ECB. The ECB must not be holding a storage block on the specified level -- it must have been previously released using the detac functions.

Format

#include   <tpfapi.h>
void       *attac(enum t_lvl level);

level
One of 16 possible values representing a valid data level from the enumeration type t_lvl, expressed as Dx, where x represents the hexadecimal number of the level (0-F). The working storage block on this core block reference word (CBRW) level is the block to be attached.

Normal Return

The pointer of type void representing the address of the start of the newly attached block.

Error Return

Not applicable.

Programming Considerations

Examples

The following example reattaches a previously detached IM0IM record to level D6.

#include <tpfapi.h>
struct im0im *inm;

  ·
  ·
  ·
inm = (struct im0im *)attac(D6);

Related Information