0

I want to use FileSystemObject to get the name of a folder and rename a file with VBScript (MoveFile). So:

Set oFSO = CreateObject("Scripting.FileSystemObject")   
folder = "collab\met\met0025\myFolder"
Set f = oFSO.GetFolder(folder)
response.write f

Path folder is on a Sharepoint server (http://collab/met/met0025/myFolder).

But I have this error message:

Erreur d'exécution Microsoft VBScript erreur '800a004c'
Chemin d'accès introuvable

Does someone know why?

Ansgar Wiechers
  • 193,178
  • 25
  • 254
  • 328
Patix80
  • 3
  • 3
  • `http:` prefix stands for Hyper Text Transfer Protocol, which isn't supportred by FSO. Could you please add the screenshot when you open `http://collab/met/met0025/myFolder`? – omegastripes May 07 '18 at 15:14
  • In fact, http://collab is a Sharepoint library. And after some tests, I've seen that it seems to not be possible to acces a file in that case. I know UNC path are important. So I test with : \\collab\met\met0025\myFolder. Dosen't work. – Patix80 May 07 '18 at 15:20
  • @Patix80 Can you map the URI to a drive letter? Something like `CreateObject("WScript.Network").MapNetworkDrive("X:", "http://collab/met/met0025/myFolder")`. – Ansgar Wiechers May 07 '18 at 19:49
  • does not work. I think Sharpoint library have some restricted acces. So, i will find a other way to solve my problem. thanks! – Patix80 May 08 '18 at 12:44

0 Answers0