Autor Beitrag
SchelmVomElm
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 154

W2K Pro
D5 Pro
BeitragVerfasst: Fr 15.10.04 13:33 
Hallo,

weiß jemand wie man die Anzahl der zu druckenden Exemplare im Druckertreiber verstellen kann? Im möchte nicht selber drucken -> Printer.Copies scheidet also aus. Die Dokumente sind teilweise sehr komplex, also scheidet mehrmaliges aufrufen von shellExecute auch aus...
jasocul
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 6393
Erhaltene Danke: 147

Windows 7 + Windows 10
Sydney Prof + CE
BeitragVerfasst: Fr 15.10.04 13:37 
Ich bin mir nicht sicher, aber vielleicht kommst du ja mit der Komponente TPrintDialog weiter.
SchelmVomElm Threadstarter
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 154

W2K Pro
D5 Pro
BeitragVerfasst: Fr 15.10.04 13:48 
Gute Idee, an sich...

Leider stellt PrintDialog.Copies nur Printer.Copies ein, aber verändert nicht die globale Einstellung im Treiber
jasocul
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 6393
Erhaltene Danke: 147

Windows 7 + Windows 10
Sydney Prof + CE
BeitragVerfasst: Fr 15.10.04 14:04 
Ich habe nochmal in meinen alten Sourcen gewühlt. Wir haben damals in einem Projekt im Programm hinterlegt, wieviel Kopien gedruckt werden. Dann Printer.Copies gesetzt und den Druckjob abgeschickt. Direkt am Drucker-Treiber haben wir das nicht hinterlegt.
Bei uns war der Grund, dass der Drucker auch anderweitig genutzt wurde. Daher konnten wir eine feste Einstellung nicht gebrauchen.
Sorry, aber mehr Infos kann ich dir nicht dazu geben.
midan23
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 48

Win XP, Mac OS X, Linux
D6 Pers, XCode 2.1, Python
BeitragVerfasst: Fr 15.10.04 14:54 
Wie man das in einem selber geschriebenen Programm realisiert weiss ich auch nicht ...
Aber wenn ich so was einstellen will, mach ich das normalerweise so :

Startmenü -> Einstellungen -> Drucker und Faxgeräte

Kontextmenü des Druckers -> Druckeinstellungen -> Erweitert -> Anzahl der Exemplare

(Falls es nicht die Art Antwort ist, die erwüscht wurde, einfach löschen ...)
SchelmVomElm Threadstarter
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 154

W2K Pro
D5 Pro
BeitragVerfasst: Mo 18.10.04 09:20 
Huahahahöhö... Ich hoffe Du willst mich nicht verarschen...
Auch wenn ich's nicht gelöscht hab - was ich garnicht kann - so war dies nicht die gewünschte Antwort.
Pille
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 105

Windows 7
DelphiXE Prof.
BeitragVerfasst: Mo 18.10.04 11:09 
Die Einstellungen müssen in der DEVMODE Struktur des Druckers vorgenommen werden meine ich (Windows API).

mfg Pille
SchelmVomElm Threadstarter
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 154

W2K Pro
D5 Pro
BeitragVerfasst: Mo 18.10.04 13:53 
wie initialisiere ich das DEVMODE Struct - in der Win SDK hab ich nichts gefunden (bin vieleicht auch blind).

Folgendes funktioniert nicht:

ausblenden Quelltext
1:
2:
3:
4:
5:
6:
7:
 
var  
  dm: _devicemodeA;
begin
  dm.dmCopies := 3;
  ResetDC(Printer.Handle,dm);
  ShellExecute(self.handle,PChar('Print'),PChar('Test.pdf'),nil,PChar('C:'),SW_HIDE);
Pille
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 105

Windows 7
DelphiXE Prof.
BeitragVerfasst: Mo 18.10.04 14:41 
Tut mir leid, ich kann mich wirklich nicht mehr daran erinnern. Ich hatte mich mal damit beschäftigt, aber nichts eigenes damit geschrieben. Irgendwo hatte ich auch ein Beispiel gefunden, ich denke innerhalb einer Komponente, die in etwa das macht, was du möchtest. Ich weiß nur leider nicht mehr wo. Sorry.

mfg Pille
Pille
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 105

Windows 7
DelphiXE Prof.
BeitragVerfasst: Mo 18.10.04 14:49 
Gerade habe ich noch das gefunden. Ich hoffe es hilft.

mfg Pille
SchelmVomElm Threadstarter
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 154

W2K Pro
D5 Pro
BeitragVerfasst: Di 19.10.04 10:10 
Danke erstmal für die Mühe - ich schau es mir mal an...