0

Unable to write file 'c:\Windows\System32\sony\src\asad.js' (NoPermissions (FileSystemError): Error: EPERM: operation not permitted, open 'c:\Windows\System32\sony\src\asad.js')

hi guys, I am new and beginner, I'm facing this error message when I create index.js file and I got this error message further more I deleted all folders from src directory so I need help how to resolve this problem how I able to create index.js file or should I reinstall and install it again?

C:\Windows\System32\sony>npm start

[email protected] start react-scripts start

Could not find a required file. Name: index.js Searched in: C:\Windows\System32\sony\src

C:\Windows\System32\sony>

2 Answers 2

1

You are trying to create your project in the windows System32 folder. This is usually reserved for operating system files, and as such has higher privileges (admin) to allow changes to files and folders. (It contains the kind of files that are often targeted by malicious code e.g. viruses, as Windows uses them to run)

Likely your IDE or development environment you are using has not been launched with administrator privileges so doesn't have permission to create or edit files in System32.

Try making your project in a new folder outside of "Windows\System32", say "C:\projects\myProject"

Sign up to request clarification or add additional context in comments.

2 Comments

thanks for your kind response, can i use d drive and save files there to avoid this issue?
You should be able to yes, if it's just a normal hard drive or partition.
0

I am not a Windows user, but I believe that C:\Windows\System32\ is an operational system folder. It's not a good practice to create your project within this folder.

Try creating your project inside with its files inside of Documents folder.

1 Comment

thanks for your kind response, can i use d drive and save files there to avoid this issue?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.