L'udf printMGv2.au3 permet d'écrire directement sur une imprimante. A l'aide d'une redirection, serait-il possible d''écrire la même chose dans un fichier ?
Ci-joint un petit exemple de code :
Code : Tout sélectionner
#NoTrayIcon
#include-once
#AutoIt3Wrapper_UseX64=N
#autoit3wrapper_res_language=1036
#EndRegion
#include <printMGv2.au3>
Global $hp
Local $mmssgg
$hp = _PrintDllStart($mmssgg);this must always be called first
_PrintSetDocTitle($hp,"TEST IMPRESSION")
_PrintStartPrint($hp)
_PrintSetFont($hp,'Arial',18,0,'bold')
$Title = "ESSAIS ESSAIS"
$tw = _PrintGetTextWidth($hp,$Title)
$th = _PrintGetTextHeight($hp,$title)
_PrintText($hp,$title,200,200)
_PrintEndPrint($hp)
_printDllClose($hp)