0

i got whole of my path deleted and after which i shutdown my pc. Later when i wanted to add another environment variable i found that whole of my path was empty

Is it possible to restore it?

2 Answers2

-1

Is it possible to restore it?

Since Java is not required for Windows 10 to function. In order to fix this particular problem, you would just add the path you removed, to the system variable yourself. In other words, just reverse the actions, you originally performed.

In order to accomplish that perform the following steps.

  1. In Search, search for and then select: System (Control Panel)
  2. Click the Advanced system settings link.
  3. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  4. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.
  5. Reopen Command prompt window, and run your java code.

Source: How do I set or change the PATH system variable?

Ramhound
  • 44,080
-1

For Windows 10 and Windows 8

  1. In Search, search for and then select: System (Control Panel)
  2. Click the Advanced system settings link.
  3. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  4. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.
  5. Reopen Command prompt window, and run your java code.
essjae
  • 1,897