Message Boards Message Boards

Exporting MIDI within a Manipulate interface

Posted 10 years ago
POSTED BY: John Stewart
2 Replies
Posted 10 years ago
POSTED BY: John Stewart

Here is one possible approach:

Manipulate[
 DynamicModule[{sound},
  sound = Sound[{SoundNote["C"], SoundNote[note], SoundNote["C5"]}];
  Column[{sound,
    Button["Save",
     Catch@Module[{file},
       file = SystemDialogInput["FileSave", ".mid"];
       If[file === $Canceled, Throw[$Failed]];
       Export[file, sound, "MIDI"]], Method -> "Queued"]}]
  ],

 {note, {"A", "B", "C", "D", "E", "F", "G"}}]
POSTED BY: David Reiss
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract