@OOPer retrying the startAccessingSecurityScopedResource now works. Code included as an answer for completion sake. I will accept @Claude31's answer as that captures the correct method. Thank you both again!
Post
Replies
Boosts
Views
Activity
@OOPer I have but similar to the user in that question I may have been doing it incorrectly. I will take another stab at using start/stopAccessingSecurityScopedResource again.
@Claude31 thank you for the quick reply! I've read through that post but to no avail. I've tried to recreate this in a dummy playground where I create a text file and move it to another both in the documents directory and that succeeded.
I'm interacting with both the documents folder of the app and the documents folder of the 'Files' app on the phone - I think the latter is my problem. I'm using the following to get the sourceUrl.
.fileImporter(isPresented: $isImporting, allowedContentTypes: [.zip], allowsMultipleSelection: false)