Files not saving to newly created folder on OneDrive by VBA

tobyolivernash

New Member
Joined
Dec 6, 2019
Messages
8
Office Version
  1. 365
Platform
  1. Windows
Hi,

I need to create a whole bunch of folders as part of a regular exercise and then save newly created files into those folders.

I've tried using MkDir and the "file system object" ways of creating a new folder onto a OneDrive location using VBA.

The folder creates just fine, it's just that I can't save any files into them!

I just get the error, document not saved.

First I thought it was my VBA code and not getting the save as method right but even when I try manually saving any files into the newly created folders, it comes up with that error.

I can create new folders manually onto the OneDrive and that works fine, its just via VBA using MkDir or FSO methods that it doesn't like.

I was wondering if anyone had any other ideas?
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
Should not be a problem with vba if you have the correct path to the directory on OneDrive. Make sure your vba path is mapped correctly from your system to the OneDrive server.
 
Upvote 0

Forum statistics

Threads
1,215,012
Messages
6,122,682
Members
449,091
Latest member
peppernaut

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top