Media files installed with MakerPlot-J (or those placed in the Media directories) do not require a full path for access, such as: !soundPlay beep.wav
The root directory for installed image files is \media.
Files in the interface's folder if not saved to the MakerPlotJ directory can be accessed with the [path] value. Such as if you create a new folder for your Interface file with a sub-folder of media:
The file, gbell.wav in the media folder can be accessed with:
!soundPlay [path]media\gbell.wav
If in the same directory as the Interface: !soundPlay [path]gbell.wav
For other media locations, the full path must be used, such as c:\gbell.wav (MPJ will handle the / for Linux and Mac).
Sound Files supported are AIFC, AIFF, AU, SND and WAVE formats.
Common image files are supported: BMP, GIF, PNG and JPG.
Note the most controls have a sound property associated which would override a sound file the event code tells it to play, such as clicking a button playing a sound in the event code. The sound property value can be made blank to prevent it overriding the coded sound file to be played.
|