Consulting

Results 1 to 5 of 5

Thread: Script not working after moving data to SharePoint

  1. #1

    Question Script not working after moving data to SharePoint

    All our data has been moved to SharePoint. In al lot of Excel files the following code is used


    MicrosoftTeams-image.png


    But now that the data is on SharePoint, this no longer works.
    Any help is appreciated

  2. #2
    Knowledge Base Approver VBAX Wizard
    Joined
    Apr 2012
    Posts
    5,642
    You use a redundant function to get the same result as

    Thisworkbook.path
    what is the result of

    Msgbox Thisworkbook.path
    zie: https://www.snb-vba.eu/VBA_Bestanden.html#L_1.8

  3. #3
    Msgbox Thisworkbook.path
    Dan komt er een message met het pad in SharePoint


  4. #4
    Knowledge Base Approver VBAX Wizard
    Joined
    Apr 2012
    Posts
    5,642
       MsgBox CreateObject("scripting.filesystemobject").GetParentFolderName(ThisWorkbook.FullName)
    of
    MsgBox CreateObject("scripting.filesystemobject").GetParentFolderName(ThisWorkbook.path)

  5. #5
    MsgBox CreateObject("scripting.filesystemobject").GetParentFolderName(ThisWorkbook .FullName)
    Displays the current folder

    MsgBox CreateObject("scripting.filesystemobject").GetParentFolderName(ThisWorkbook .path)
    Returns the subfolder
    Last edited by Aussiebear; 08-15-2022 at 05:48 AM. Reason: Posts are required to be in English

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •