CD open close/de
Deutsch · English
(Windows only)
Zurück zur Seite Code Beispiele.
Dieser Artikel beschäftigt sich mit der Windowsprogrammierung.
Die Prozedur öffnet bzw. schliesst ein CD / DVD Laufwerk.
uses
MMSystem, ...;
...
procedure subCDAufZu(chrDriveChar: char; blnOeffnen: boolean);
begin
if mciSendString(PChar('open ' + chrDriveChar + ': type cdaudio alias cdlw'),
nil, 0, 0) = 0 then
begin
if blnOeffnen = True then
mciSendString('set cdlw door open wait', nil, 0, 0)
else
mciSendString('set cdlw door closed wait', nil, 0, 0);
mciSendString('close cdlw', nil, 0, 0);
end;
end;
...From the Free Pascal wiki, page "CD open close/de", as it stood on 2020-09-09 after a change by Bart, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's Licensing page. If you have concerns about this material, message the admin.