Ver Mensaje Individual
  #1 (permalink)  
Antiguo 14/09/2007, 10:05
Patricia_TS
 
Fecha de Ingreso: septiembre-2007
Mensajes: 9
Antigüedad: 17 años, 7 meses
Puntos: 0
Pregunta Imprimir Directamente con Php

Hola, por favor me gustaria que me ayuden con esto, tengo una función que debería imprimir directamente, sin que salgan las propiedades de impresion, pero me sale error.
Warning: printer_start_doc() [function.printer-start-doc]: couldn't allocate new print job in H:\....
Warning: printer_start_page() [function.printer-start-page]: couldn't start a new page in H:

No se si sera problemas con la red, o si esta mal el codigo que mando:

Código PHP:
$handle =printer_open('\\\\192.168.-->(donde esta conectadala impresora)\\Xerox Phaser 3120');
//$handle=printer_open();
printer_set_option($handlePRINTER_MODE"RAW"); 
printer_start_doc($handle"Mi Documento");
printer_start_page($handle);
$font printer_create_font('Arial',55,30,400,false,falsefalse,0);
printer_select_font($handle$font);
printer_write($handle'IMPRIMIENDO DATOS');
//printer_draw_text($handle, "IMPRIMIENDO DATOS",50,400);
printer_delete_font($font);
printer_end_page($handle);
printer_end_doc($handle);
printer_close($handle); 

Y cuando pongo este codigo:

Código PHP:
$var_dump printer_list(PRINTER_ENUM_NETWORK); 
while(list(
$key$value) = each($var_dump)) 

echo 
"$key, $value"

echo 
var_dumpprinter_list(PRINTER_ENUM_NETWORK PRINTER_ENUM_SHARED) ); 
Que son las impresoras que estan en red, no sale la impresora a la cual mando el trabajo, el detalle, es que sí, está en red.
Necesito ayuda urgente por favor, que puedo hacer. Gracias.