How to get authentication for access file with Administrator rights

Using one of my own maintenance program (X), Ineed to write or modify files (Y) in the “Y/Contents/Resources” folder.
I need to run that from either Administrator user or Standard user.
I fall on this problem: the Xojo file system doesn’t execute the job (ex. CopyFileTo) because it doesn’t ask for Administrator Authentication, so can’t write.
Doing the job by hand using the finder asks for Administrator Authentication and goes normally.
Why using Xojo “.CopyToFile” or others doesn’t?
Xoxo should propose an automatic solution for that, it is made to avoid users such system hard work.

Is there some significant information about that point in documentation or Example projects?
Is there a way to bypass this issue?

You can ask for authentication. There is a solution available in the MBS plugin and also something called AuthoriationShell.

But you really should think about your approach. The application can’t be changed. How about copying the files from your resources folder to your application support folder and then manipulate the files there? Please tell us more about what you want to accomplish.

Doing that would negate any signing applied to your app(Y). As Beatrix suggested, you should consider another approach.

That “approach” is really what the ‘Application Support’ or "Documents’ folder are for. AppSupport holds the app specific stuff the user doesn’t have to see directly, or use outside the app. Examples are files that hold templates your apps uses, or temporary caches you want to keep persistent between sessions.

The Documents folder has the stuff the user would use outside the app, perhaps to give to someone or use with yet another app. Examples are photographs, sound files, text files, RTF files, etc.

Anything in your bundle should only be read-only and things your app uses to run; it’s “braintrust”, if you will. None of it should be dynamic.

Windows runs the same way,

Thanks