Quantcast
Channel: Adobe Community : Popular Discussions - Archived Discussions
Viewing all articles
Browse latest Browse all 21156

playing local sound file

$
0
0
I need to play an mp3 file in my AIR app. But I won't necessarily know the path to the file because I need to use things like the storage directory. So, would I have to do something like this to get that done:

var file:File = File.applicationStorageDirectory.resolvePath("path/to/mp3");
var urlRequest:URLRequest = new URLRequest(file.nativePath);

and then load the sound from that? Or is there some way that AIR has provided to skip the first step?

Thanks!
Kyle

Viewing all articles
Browse latest Browse all 21156

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>