Portable Script for playing external mp3 file?
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Portable Script for playing external mp3 file?
Can anyone give me a script for a stack that uses the player object to play an external audio file? The trick is, the stack has to be portable so that I can move it to another computer and the player will still work, in other words, the player will still 'see' the mp3 file no matter which computer it's on.
Re: Portable Script for playing external mp3 file?
Hi thomthib,
If I understand correctly, what you will need to do is use the "Copy Files" section of your standalone application settings to copy any audio files that you wish to have included with your standalone.
As these will now be included with your standalone, you will be able to reference them via script.
From a standalone, you can then work with defaultFolder property to generate the URL to your audio files.
I hope this gives you some leads.
Kind Regards,
Neil Roger
--
LiveCode Support Team ~ http://www.livecode.com
-
If I understand correctly, what you will need to do is use the "Copy Files" section of your standalone application settings to copy any audio files that you wish to have included with your standalone.
As these will now be included with your standalone, you will be able to reference them via script.
From a standalone, you can then work with defaultFolder property to generate the URL to your audio files.
I hope this gives you some leads.
Kind Regards,
Neil Roger
--
LiveCode Support Team ~ http://www.livecode.com
-
Re: Portable Script for playing external mp3 file?
Thank you for your response, Neil. I can’t include the audio files in the standalone. My program is a text processor that allows foreign language teachers to create hypermedia texts by linking information to specific words. Then when students click on the words, a translation will appear as well as other relevant info. Teachers can also link an external audio or video file and use the transcript as the reading material. When I link the external file to the player object, everything works fine. When I move the entire project to a different computer, everything works fine except for the player. The player appears but when you click on the PLAY button, nothing happens. It seems the player can’t see the external file anymore. I’ve only tried this on Macintosh. This was not a problem for years. It only became a problem when I started using LC 7. A demo of my editor is here: https://www.youtube.com/watch?v=WVozjsL1DX0
I greatly appreciate any suggestion you might have.
I greatly appreciate any suggestion you might have.