Arduino IDE wont start on win 10

Ive tried to restart my pc, if uninstalled and reinstalled, and ive tried older versions but the thing still wont start. Ive also turned off my antivirus and firewall but that didnt work either. I just ran the debug and this is what it said:

Loading configuration...
Initializing packages...
Preparing boards...
java.io.IOException: The cloud file provider is not running
        at java.io.FileInputStream.readBytes(Native Method)
        at java.io.FileInputStream.read(FileInputStream.java:255)
        at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284)
        at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326)
        at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178)
        at java.io.InputStreamReader.read(InputStreamReader.java:184)
        at java.io.BufferedReader.fill(BufferedReader.java:161)
        at java.io.BufferedReader.readLine(BufferedReader.java:324)
        at java.io.BufferedReader.readLine(BufferedReader.java:389)
        at processing.app.legacy.PApplet.loadStrings(PApplet.java:270)
        at processing.app.helpers.PreferencesMap.load(PreferencesMap.java:100)
        at processing.app.helpers.PreferencesMap.load(PreferencesMap.java:74)
        at processing.app.packages.UserLibrary.create(UserLibrary.java:65)
        at cc.arduino.contributions.libraries.LibrariesIndexer.scanLibrary(LibrariesIndexer.java:188)
        at cc.arduino.contributions.libraries.LibrariesIndexer.scanInstalledLibraries(LibrariesIndexer.java:157)
        at cc.arduino.contributions.libraries.LibrariesIndexer.rescanLibraries(LibrariesIndexer.java:124)
        at cc.arduino.contributions.libraries.LibrariesIndexer.setLibrariesFolders(LibrariesIndexer.java:106)
        at processing.app.BaseNoGui.onBoardOrPortChange(BaseNoGui.java:682)
        at processing.app.Base.onBoardOrPortChange(Base.java:1297)
        at processing.app.Base$11.actionPerformed(Base.java:1498)
        at processing.app.Base.rebuildBoardsMenu(Base.java:1474)
        at processing.app.Base.<init>(Base.java:262)
        at processing.app.Base.main(Base.java:140)
java.lang.NullPointerException
        at processing.app.helpers.PreferencesMap.load(PreferencesMap.java:101)
        at processing.app.helpers.PreferencesMap.load(PreferencesMap.java:74)
        at processing.app.packages.UserLibrary.create(UserLibrary.java:65)
        at cc.arduino.contributions.libraries.LibrariesIndexer.scanLibrary(LibrariesIndexer.java:188)
        at cc.arduino.contributions.libraries.LibrariesIndexer.scanInstalledLibraries(LibrariesIndexer.java:157)
        at cc.arduino.contributions.libraries.LibrariesIndexer.rescanLibraries(LibrariesIndexer.java:124)
        at cc.arduino.contributions.libraries.LibrariesIndexer.setLibrariesFolders(LibrariesIndexer.java:106)
        at processing.app.BaseNoGui.onBoardOrPortChange(BaseNoGui.java:682)
        at processing.app.Base.onBoardOrPortChange(Base.java:1297)
        at processing.app.Base$11.actionPerformed(Base.java:1498)
        at processing.app.Base.rebuildBoardsMenu(Base.java:1474)
        at processing.app.Base.<init>(Base.java:262)
        at processing.app.Base.main(Base.java:140)

Can anyone please make sense of this and help me?? I just got a mega 2560 and a bunch of parts and im eager to try them out!!

My suspicion is that your user directory is located in your OneDrive and you're not connected to the cloud.

How can i check that?

I disabled onedrive and my god you were right!!! Thankyou!

You're welcome. I'm glad to hear it's working now.

I'll provide some additional information about the problem in case it will be helpful to you:

The Arduino IDE uses two folders outside of the Arduino IDE installation folder. If it can't access either of those folders on startup then it refuses to start. It's not clear to me which of those two folders were the problem (or it may be both of them). If you're not satisfied with your current workaround of disabling onedrive, then another solution you might use is to move the problematic folder outside of onedrive.

The one I suspect most is the sketchbook folder. Its location is set in the Arduino IDE at File > Preferences > Sketchbook location. So if the sketchbook folder is located in your onedrive and you want to move it out of onedrive then you can just change the location in File > Preferences > Sketchbook location to any other convenient location on your computer and then copy any files you might have saved in your old sketchbook folder to the new location.

The other folder is located at C:\Users{username}\AppData\Local\Arduino15. Note that the AppData folder is hidden by default so you need to check the box next to View > Hidden items in Windows Explorer to be able to see it. The way to change the location of this folder is by running the Arduino IDE in portable mode. That is done by creating a folder named portable under the Arduino IDE installation folder. The Arduino IDE needs to be able to write to this folder and Windows is very restrictive of the C:\Program Files and C:\Program Files (x86) folders so you may need to install the Arduino IDE to a different location to be able to use portable mode. In portable mode, the Arduino IDE will use the portable folder you created instead of the C:\Users{username}\AppData\Local\Arduino15 folder.