Getting Printer Configuration Information Example for C#

private void GetPrinterConfigInfo(ref LTDICPRNSCULib.LEADDicomPrintSCU objPrintSCU)
{
   // Assume that the Association is already established
   // Query the Print SCP for the printer configuration information
   string sMsg = null;
   if (objPrintSCU.PrinterConfiguration.Get() == (short)LTDicomKernelLib.DicomErrorCodes.DICOM_SUCCESS)
   {
      // We will display only the Attributes of the first Printer Configuration Item
      if (objPrintSCU.PrinterConfiguration.PrinterConfigItems.Count > 0)
      {
         foreach (LTDICPRNSCULib.LAttribute Attrib in objPrintSCU.PrinterConfiguration.PrinterConfigItems.Item(0).Attributes)
         {
            sMsg = sMsg + Attrib.Name + ": " + Attrib.Value + System.Environment.NewLine;
         }
         MessageBox.Show(sMsg, "Printer Config Info");
      }
   }
}