Highlighted

File exists always false

New Here ,
Jun 23, 2014

Copy link to clipboard

Copied

I'm making a mobile app for iOS and I have files in both the applicationDirectory (inside the app) and the cacheDirectory.

No matter what I do a check on file.exists always returns false even though it is there - it's a video and it can play so it's there alright.

What is going on?

I have a string representing the path eg. "/assets/video.mp4"

var f:File = File.applicationDirectory.resolvePath(filePath);

trace(f.exists) //false

TOPICS
Development

Views

85

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

File exists always false

New Here ,
Jun 23, 2014

Copy link to clipboard

Copied

I'm making a mobile app for iOS and I have files in both the applicationDirectory (inside the app) and the cacheDirectory.

No matter what I do a check on file.exists always returns false even though it is there - it's a video and it can play so it's there alright.

What is going on?

I have a string representing the path eg. "/assets/video.mp4"

var f:File = File.applicationDirectory.resolvePath(filePath);

trace(f.exists) //false

TOPICS
Development

Views

86

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jun 23, 2014 0

Have something to add?

Join the conversation