Specified folder does not exist error for all folders

6 vues (au cours des 30 derniers jours)
Bryn Phillips
Bryn Phillips le 2 Mai 2019
Commenté : Bryn Phillips le 2 Mai 2019
Hi all,
I'm trying to write a video File from images. The script used to work but I've since updated to windows 10 and reinstalled MATLAB and I am getting the following error:
" Error using SV_Video_Capture (line 52)
The specified folder, D:\OneDrive\OneDrive - XXXX\Documents\MATLAB, does not exist "
SV_Video_Capture is the name of the script.
The Code it relates to is:
VidName = strcat('Test','.avi') ;
f = fullfile(userpath,VidName);
outputVideo = VideoWriter(f) ; This is line 52.
The script is throwing this error regardless of what I change the path to in fullfile (I was usiung userpath as it's a default search directory) this includes just using cd. Matlab can "see" the folder and knows it exists as running exist returns 7 - meaning the folder is there.
Any help would be much appreciated.

Réponses (1)

Jan
Jan le 2 Mai 2019
Modifié(e) : Jan le 2 Mai 2019
This might be a problem with OneDrive folders. Did you see this already: https://www.mathworks.com/matlabcentral/answers/354614-cd-to-onedrive-doesn-t-work-on-windows-10-build-16273-1 ?
"throwing this error regardless of what I change the path to in fullfile" - Then please post, which other pathes are failing. Where exactly is the userpath? On the OneDrive again?
  1 commentaire
Bryn Phillips
Bryn Phillips le 2 Mai 2019
I have solved this - it was my own error. When entering the filename I had it surrounded by quote marks - not inverted commas.
Thank you for your quick reply regardless.

Connectez-vous pour commenter.

Catégories

En savoir plus sur File Operations dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by