Angelo2449
Guest
Hallo alle,
Ich schrieb ein kleines Programm, das die Windows 10 Zwischenablage verwendet.
konzeptuell ist das Programm sehr einfach, es führt kleine Operationen nach zwei Antworten (ja - nein), die durch die Windows 10 Clipboard übergeben werden.
die beiden Antworten (verantwortlich und antworten2), obwohl sie eine Verzögerung von 100 ms eingeführt hat, scheitert manchmal und erhält diesen Fehler:
fehler: openclipboard versagt.
Danke.
Ich schrieb ein kleines Programm, das die Windows 10 Zwischenablage verwendet.
konzeptuell ist das Programm sehr einfach, es führt kleine Operationen nach zwei Antworten (ja - nein), die durch die Windows 10 Clipboard übergeben werden.
Code:
(defunct deletefree) (/ re1 re2 control7 fp4 fp5)
(Leitlinien)
(Sectq und 1$ nil)
(Setcliptext)
(Start "c:\\autocadsupport\\libertytre\eliminalibretto.exe "c:\\autocadsupport\\libertytre\\\\eliminalibretto.tkn")
(setq stop (+ 100 (getvar 'millisecs)))
(while)
(while (und (/= re1$ "yes") (/= re1$ "no")
(setq re1$ (getcliptext)
;
(princ "\n")
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >
(princ resp1$)
(princ "\n")
(setq stop (+ 100 (getvar 'millisecs)))
(while)
(falls (und/= re1$ "yes") (/= re1$ "no")
(Progn)
(Alert "Lesefehler")
(Sectq und 1$ nil)
(Setcliptext)
(vl-exit-with-error "aus dem Programm herausfahren")
;
;
(falls)
(Progn)
(setq dflb (vl-file-delete "c:\\autocadsupport\\\\\\librettopregeo.dat"))
(falls)
(alert "pregeo.dat Datei gelöscht")
(Progn)
(Alert "die Datei bookpregeo existiert nicht)
(Sectq und 1$ nil)
(Setcliptext)
(vl-exit-with-error "aus dem Programm herausfahren")
;
;
;
;
(falls)
(Progn)
(alert " Löschbuchpregeo storniert)
(Sectq und 1$ nil)
(Setcliptext)
(vl-exit-with-error "aus dem Programm herausfahren")
;
;
(Sectq und 1$ nil)
(Setcliptext)
(Sectq
:---------------------------------------------------------------------------------------------------------------------------------------------------------
(startapp "c:\autocadsupporto\\libertytre\resetprimariga.exe "c:\\autocadsupport\\libertytre\resetprimariga.tkn")
(setq stop (+ 100 (getvar 'millisecs)))
(while)
(while (und/= re2$ "yes") (/= re2$ "no")
(setq re2$ (getcliptext)
;
(princ "\n")
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >
(princ resp2$)
(princ "\n")
(setq stop (+ 100 (getvar 'millisecs)))
(while)
(falls (und (/= re 2$ "yes") (/= re 2$ "no"))
(Progn)
(Alert "Lesefehler")
(Sectq
(Setcliptext)
(vl-exit-with-error "aus dem Programm herausfahren")
;
;
(falls)
(Progn)
(setq Primariga nil)
(setq control7 "c:\\autocadsupport\\contatori\\counter.dat")
(falls Regelung 7)
(Progn)
(setq fp4 (open "c:\\\\\\autocadsupport\\\contatori\\counter.dat" "r"))
(setq count (read line fp4))
(setq Schritt (read-line fp4))
(Schließe fp)
;
;
(setq zählt "1000")
(wenn (= Schritt nil)
(Sieben Schritt "10")
;
(setq fp5 (open "c:\\\\\autocadsupport\\\contatori\\counter.dat" "w"))
(writeline count fp5)
(Schreib-Linie Schritt fp5)
(Schließe fp)
(Sectq
(Setcliptext)
(Identifizierung setq "000100")
(Alert "Reset Referenzlinie aufgetreten")
;
;
(falls)
(Progn)
(Alert "Reset der stornierten Erlösungslinie")
(Sectq
(Setcliptext)
(Identifizierung setq "000000000")
;
;
;
fehler: openclipboard versagt.
Danke.