LDicomDS::GetNextUnusedPrivateTag

#include " Ltdic.h "

L_UINT16 LDicomDS::GetNextUnusedPrivateTag(pPrivateCreatorDataElement,puTag)

pDICOMELEMENT pPrivateCreatorDataElement;

/* pointer to a Private Creator Data Element */

L_UINT32 * puTag;

/* pointer to a variable that is updated with the tag */

Returns the next available unused tag reserved by the Private Creator Data Element. This feature is available in version 16 or higher.

Parameter

Description

pPrivateCreatorDataElement

Pointer to the Private Creator Data Element.

puTag

Pointer to a variable that is updated with the next unused private tag.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

This method is used together with any of the following functions:

LDicomDS::CreatePrivateCreatorDataElement

LDicomDS::FindFirstPrivateCreatorDataElement

LDicomDS::FindNextPrivateCreatorDataElement

to create private elements in a DICOM data set. For more information on private elements, see LDicomDS::CreatePrivateCreatorDataElement.

Use this method with an existing private creator data element to create private elements. If successful, argument *puTag will contain the next available unused tag that has been reserved by the private creator data element pointed to by argument pPrivateCreatorDataElement.

For example, suppose the following tags exist in a DICOM data set:

 

(0017, 0012)

© private creator data element

 

(0017, 1200)

© private element

 

(0017, 1201)

© private element

 

(0017, 1205)

© private element

After a successful call to LDicomDS::GetNextUnusedPrivateTag, *puTag will contains the value 0x00171202, which can be used with LDicomDS::InsertElement to add a new private element.

Required DLLs and Libraries

LTDIC

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

Platforms

Win32, x64

See Also

Functions:

LDicomDS::CreatePrivateCreatorDataElement, LDicomDS::FindFirstPrivateCreatorDataElement, LDicomDS::FindNextPrivateCreatorDataElement, LDicomDS::FindFirstPrivateElement, LDicomDS::FindNextPrivateElement, Class Members

Topics:

Working with Data Sets

 

Data Sets: Inserting and Deleting Data Set Members

 

How to Disable the Automatic Loading of the default DICOM IOD Table

Example

For an example, refer to LDicomDS::CreatePrivateCreatorDataElement