LDicomAssociate::GetApplication

#include "ltdic.h"

L_VOID LDicomAssociate::GetApplication(strApplication, SizeInWords)

Gets the Application Context for the DICOM Associate.

Parameters

L_TCHAR * strApplication

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

L_UINT32 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

Platforms

Win32, x64

See Also

Functions

Topics

Example

L_INT LDicomAssociate_GetApplicationExample(LDicomAssociate *m_pDicomAssociate) 
{ 
   L_INT    nRet; 
   CString  strMsg; 
   L_TCHAR  szApplication[PDU_MAX_UID_SIZE+1]; 
 
   //create the Associate Class as Request 
   m_pDicomAssociate = new LDicomAssociate(TRUE); 
 
   //Getthe current Application Context 
   m_pDicomAssociate->GetApplication(szApplication, PDU_MAX_UID_SIZE+1); 
 
   strMsg.Format(TEXT("Current Application Context: %s"), szApplication); 
   AfxMessageBox(strMsg); 
 
   //change it 
   nRet = m_pDicomAssociate->SetApplication(TEXT("9.9.999.99999.9.9.9.9")); 
   if(nRet != DICOM_SUCCESS) 
      return nRet; 
 
   m_pDicomAssociate->GetApplication(szApplication, PDU_MAX_UID_SIZE+1); 
 
   strMsg.Format(TEXT("New Application Context %s"), szApplication); 
   AfxMessageBox(strMsg); 
 
   //Free associate 
   delete m_pDicomAssociate; 
 
   return DICOM_SUCCESS; 
} 
Help Version 21.0.2020.8.24
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS DICOM C++ Class Library Help