Copy link to clipboard
Copied
I have a problem loading images into a tilelist it works fine on windows but the image is missing with the Mac
the code I used is below, photoDialog is a movie clip that has a tilelist dirImages
for each( var file:File in dirListing ) {
if( !file.isDirectory && !file.isSymbolicLink &&
(file.extension == "PNG" ||
file.extension == "png" ||
file.extension == "jpg" ||
file.extension == "JPG" ||
file.extension == "JPEG" ||
file.extension == "jpeg" ||
file.extension == "GIF" ||
file.extension == "gif" ||
file.extension == "BMP" ||
file.extension == "bmp" ))
{
var o:Object = new Object();
o.caption = file.name;
o.data = file.nativePath;
o.source = file.nativePath;
o.file = file;
photoDialog.dirImages.addItem( o );
}
}
How can I best achieve this on both windows and mac?
Copy link to clipboard
Copied
Instead of using file.nativePath, can you try file.url instead?
Chris