EnumPrinterDrivers 枚举指定系统中已安装的打印机驱动程序 
  EnumPrinters 枚举系统中安装的打印机  
  EnumPrintProcessorDatatypes 枚举由一个打印处理器支持的数据类型 
  EnumPrintProcessors 枚举系统中可用的打印处理器 

解决方案 »

  1.   

    with TPrinter.Create do
        try
          if Printers.Count =0 then
            raise Exception.Create('没有安装打印机');
        finally
          Free;
        end;
      

  2.   

    use里加上 printers,对楼上的补充
    with TPrinter.Create do
        try
          if Printers.Count =0 then
            showmessage('没有安装打印机');
        finally
          Free;
        end;
      

  3.   

    系统中的打印机列表printer.printers
      

  4.   

    用showmessage不好,因为我们的目的是在没有打印机的时候能跳出打印过程,所以要用 raise execption。无论你怎样嵌套调用,都可经直接跳出。