Comment utiliser SetDefaultPrinter dans une application console ?
J'ai essayé, sans succès :
Dans tous les cas, j'obtiens une EAccesViolation. :bug:Code:
1
2
3
4 if not SetDefaultPrinter(PChar(MaVariableChaine)) then if not SetDefaultPrinter(PChar(MonTableauDeChar)) then if not SetDefaultPrinter(nil) then if not SetDefaultPrinter('') then
Que faut-il lui donner ?
:hola: