Sign in Join
Wiki copytemporary

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.

pascal
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.

Revision 1, last changed by WikiArchive .

Edited on wiki.freepascal.org by 4 people, 2013–2020

From the official wiki's backup of 26 May 2024: who edited this page there, and when. Edits made there after that date were not recorded, and the earlier versions are not shown here; the main page says why.

WhenWhoWhat changed
OlafCreated page
Olaf (minor)
Olaf (minor)
Olaf (minor)
FTurtle
TrevFixed syntax highlighting; deleted category already in page template (minor)
Bart

Talk about this page

Nobody has opened a bench for this page yet. Sign in to open one.