L_DicomGetApplication

#include "ltdic.h"

L_LTDIC_API L_VOID L_DicomGetApplication(hPDU, strApplication, SizeInWords)

HDICOMPDU hPDU;

/* a DICOM Associate handle */

L_TCHAR * strApplication;

/* buffer to be updated */

L_UINT32 SizeInWords;

/* size of the destination string buffer */

Gets the Application Context for the specified DICOM Associate.

Parameter

Description

hPDU

A DICOM Associate handle.

strApplication

Buffer to be updated with the Application Context for the specified DICOM Associate.

SizeInWords

Size of the destination string buffer.

Returns

None.

Comments

The default value for the Application Context is "1.2.840.10008.3.1.1.1" (UID_APPLICATION_CONTEXT_NAME).

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:

L_DicomSetApplication

Topics:

Working with DICOM Associate Connections

Example

L_INT DicomGetApplicationExample(HDICOMPDU hPDU)
{
   L_INT nRet;

   /* display current Application Context */
   L_TCHAR szApplication[PDU_MAX_UID_SIZE+1];

   L_DicomGetApplication(hPDU, szApplication, PDU_MAX_UID_SIZE+1);
   MessageBox(NULL, szApplication, TEXT("Test"), MB_OK);
   /* change it */
   nRet = L_DicomSetApplication(hPDU, TEXT("9.9.999.99999.9.9.9.9"));
   if (nRet != DICOM_SUCCESS)
      return nRet;

   L_DicomGetApplication(hPDU, szApplication, PDU_MAX_UID_SIZE+1);
   MessageBox(NULL, szApplication, TEXT("Test"), MB_OK);
   return DICOM_SUCCESS;
}