PRINTSCUPRINTJOBREPORT

#include "ltdic.h"

L_VOID pEXT_CALLBACK Your Function(hCU, pszPrintJobInstanceUID, uEventTypeID, pReportInformation, pUserData)

HDICOMPRINTSCU hCU; handle to DICOM Print SCU
const L_TCHAR pszPrintJobInstanceUID; pointer to the instance UID of the print job
L_INT16 uEventTypeID; event type ID
pPRINTERREPORTINFO pReportInformation; pointer to job report information
L_VOID* pUserData; pointer to user-defined data

Called when a Print Job status report is received from the Print SCP.

Parameter Description
hCU Handle to the DICOM Print SCU
pszPrintJobInstanceUID Pointer to the character string that contains the SOP Instance UID of the Print Job SOP Instance for which the status report was sent.
uEventTypeID The Event Type ID which indicates the status of the Print Job. The following values are possible:
  Value Meaning
  1 Event Type Name = Pending
  2 Event Type Name = Printing
  3 Event Type Name = Done
  4 Event Type Name = Failure
pReportInformation Pointer to a PRINTJOBREPORTINFO structure that specifies Print Job information. This can be NULL.
pUserData Pointer to user-defined data

Returns

None

Comments

This callback function is called whenever the Print SCU receives a report from the Print SCP about the changes in the status of a Print Job. The intended Print Job is specified by its SOP Instance UID. If the Print Job SOP Class is supported on the Association, this function is expected to be called. Otherwise, it will never be called.

If the status of the Print Job is Pending or Failure, the Print SCP is supposed to supply additional information about the pending/error condition in the Attribute Execution Status Info (the pszExecutionStatusInfo member of the PRINTJOBREPORTINFO structure).

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_DicomPrintSCUGetPrintJobInstanceUID, L_DicomPrintSCUGetPrintJobInfo

Topics:

Print Management SCU

 

DICOM Print Management Service Class User: Functions

Example

L_VOID EXT_CALLBACK MyPRINTSCUPRINTJOBREPORT (HDICOMPRINTSCU hCU, const L_TCHAR * pszPrintJobInstanceUID, L_UINT16 uEventTypeID, const pPRINTJOBREPORTINFO pReportInfo, L_VOID* pUserData) 
{ 
   L_TCHAR szMsg[512];  
 
   wsprintf(szMsg, TEXT("Print Job SOP Instance UID: %s"), pszPrintJobInstanceUID);  
 
   L_TCHAR  * pszEventTypeName = TEXT("Pending"); 
 
   switch (uEventTypeID)  
   { 
   case 2:  
      pszEventTypeName = TEXT("Printing"); 
      break;  
 
   case 3: 
      pszEventTypeName = TEXT("Done"); 
      break;  
 
   case 4:  
      pszEventTypeName = TEXT("Failure"); 
      break; 
   } 
 
   wsprintf(szMsg, TEXT("%s\nEvent Type Name: %s"), szMsg, pszEventTypeName);  
 
   if (pReportInfo)  
 
   { 
      if (pReportInfo->pszExecutionStatusInfo)  
 
      { 
         wsprintf(szMsg, TEXT("%s\nExecution Status Info: %s"), 
            szMsg, pReportInfo->pszExecutionStatusInfo);  
      } 
 
      if (pReportInfo->pszFilmSessionLabel)  
 
      { 
         wsprintf(szMsg, TEXT("%s\nFilm Session Label: %s"), 
            szMsg, pReportInfo->pszFilmSessionLabel);  
      } 
 
      if (pReportInfo->pszPrinterName)  
 
      { 
         wsprintf(szMsg, TEXT("%s\nPrinter Name: %s"), 
            szMsg, pReportInfo->pszPrinterName);  
      } 
   } 
 
   MessageBox(NULL, szMsg, TEXT("Print Job Status Report"), MB_OK);  
} 
Help Version 20.0.2019.3.12
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2019 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS DICOM C API Help