+ Reply to Thread
Results 1 to 6 of 6

Add or Remove Passwords from Files

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    11-29-2016
    Location
    USA
    MS-Off Ver
    365
    Posts
    116

    Add or Remove Passwords from Files

    I have a script that loops through the files in a choosen folder and is supposed to protect or unprotect the workbook depending on what the user types into a Application.InputBox.

    The script will cycle through the files but does not either protect or unprotect them as expected. And from all my research, the code seems to be correct.
    I am looking for a little guidance with the code below.

    I have sectioned off the part I need help with.

    Sub RemovePassword()
    'Modified from a post from Stack
    'https://stackoverflow.com/questions/53885596/remove-password-from-excel-files
      
      ' String Lists
      Const cStrExtensions As String = "*.xls*"
      Const cStrPassword As String = "*knights"
    
      Dim strFolderPath As String     ' Search Folder
      Dim strFileName As String       ' Current File Name (Workbook)
      Dim iCost As Long
      Dim MyValue As String
      Dim Response As String
      
    'Confirm that the user wants to complete action
        If MsgBox("This action will Lock or Unlock sensitive salary files, " & vbNewLine & _
                        "Do you want to continue? ", vbCritical + vbYesNo, "WARNING") = vbYes Then
                        
                                                  
    'Ask the user what they want to do, lock or unlock
    ' Display dialog box
    MyValue:
        MyValue = UCase(Application.InputBox(Prompt:="This action will Lock or Unlock Salary files" & vbNewLine & _
                                                    "What would you like to do, Lock or Unlock?", Title:="WHAT CHA WANNA DO??"))
        
        
    '    'I NEED HELP WITH THIS BIT.  will post a seperate post for this question
    '    ' Want to test if the user entered a correct value before proceeding
    '        If MyValue <> "LOCK" Or MyValue <> "UNLOCK" Then
    '        Response = MsgBox("You only Have 2 Choices, Locked or Unlocked", vbYesNo, "TRY AGAIN?")
    '            If Response = vbYes Then
    '              GoTo MyValue
    '            Else
    '              MsgBox "Check Ya Later"
    '            End If
    '            Exit Sub
                                                    
                                                    
                                                    
      With Application
        .ScreenUpdating = False
        .DisplayAlerts = False
      End With
    
    
      With ThisWorkbook.ActiveSheet
    
        ' Choose Search Folder
        With Application.FileDialog(msoFileDialogFolderPicker)
          If .Show = False Then Exit Sub
          strFolderPath = .SelectedItems(1) & "\"
        End With
    
        ' Loop through folder to determine Current File Name (Workbook).
        ' Use the cost center as part of the password
        strFileName = Dir(strFolderPath & cStrExtensions)
        iCost = Trim(Left(strFileName, InStr(strFileName, " ") - 1))
    '    Debug.Print strFileName
    '    Debug.Print iCost
    
        ' Loop through files in folder.
        Do While strFileName <> ""
    
          ' Open each file in folder
          'Workbooks.Open strFolderPath & strFileName
        Workbooks.Open Filename:=strFolderPath & strFileName, _
                                                        Password:=iCost & cStrPassword
    
    
        
    '####################################################################################
        ' I NEED HELP WITH THIS PART
        ' THE PROTECT AND UNPROTECT DO NOT SEEM TO BE DOING WHAT THEY ARE SUPPOSED TO
        ' I DO NOT GET AN ERROR
        
        
            Select Case MyValue
            
        'Lock all files in the folder
            Case Is = "LOCK"
              With ActiveWorkbook
                 .Protect Password:=iCost & cStrPassword, Structure:=True, Windows:=True
                 .Close True
              End With
            
        'Unlock all files in the folder
            Case Is = "UNLOCK"
              With ActiveWorkbook
                 .Unprotect iCost & cStrPassword
                 .Close True
              End With
            End Select
    '####################################################################################
    
    
          strFileName = Dir()
          ' Exclude this workbook.
          If .Parent.Name = strFileName Then strFileName = Dir()
    
        Loop
    
      End With
    
    ProcedureExit:
    
      With Application
        .ScreenUpdating = True
        .DisplayAlerts = True
      End With
    
    
        'Exit if user clicks no
        Else
                MsgBox "D'OH!      ", vbInformation, "CHECK YA LATER!"
        End If
        Exit Sub
    
    'End the MyValue test
            'End If
    
    End Sub

  2. #2
    Forum Expert
    Join Date
    08-17-2007
    Location
    Poland
    Posts
    2,533

    Re: Add or Remove Passwords from Files

    ' 'I NEED HELP WITH THIS BIT.
    ' ' Want to test if the user entered a correct value before proceeding
    A bit different than you thought:
    (...)
    'Ask the user what they want to do, lock or unlock
    ' Display dialog box
    Again:
        MyValue = UCase(Application.InputBox(Prompt:="This action will Lock or Unlock Salary files" & vbNewLine & _
                                                    "What would you like to do, (L)ock or (U)nlock?", Title:="WHAT CHA WANNA DO??"))
        
        If TypeName(MyValue) = "Boolean" Then Exit Sub
        
        Select Case Left(UCase(MyValue), 1)
          Case "L", "U"
          Case Else
            MsgBox "You only Have 2 Choices, Locked or Unlocked", vbExclamation
            GoTo Again
        End Select
    (...)
    ' I NEED HELP WITH THIS PART
    ' THE PROTECT AND UNPROTECT DO NOT SEEM TO BE DOING WHAT THEY ARE SUPPOSED TO
    ' I DO NOT GET AN ERROR
    You found the wrong protection. You want to password protect the file on opening, but you used workbook structure protection. Keep looking.

    Artik

  3. #3
    Forum Contributor
    Join Date
    11-29-2016
    Location
    USA
    MS-Off Ver
    365
    Posts
    116

    Re: Add or Remove Passwords from Files

    First off thank you for taking the time to review and answer my questions, this is very helpful.


    I am however, still unable to protect workbooks??

    '####################################################################################
        ' I NEED HELP WITH THIS PART
        ' THE PROTECT AND UNPROTECT DO NOT SEEM TO BE DOING WHAT THEY ARE SUPPOSED TO
        ' I DO NOT GET AN ERROR
        ' https://exceloffthegrid.com/vba-code-protect-unprotect-workbooks/
        
            Select Case MyValue
            
        'Lock all files in the folder
            Case Is = "LOCK"
              With ActiveWorkbook
                 .Protect Password:=iCost & cStrPassword
                 
                 'Save file with password required to open and modify the file
                 .SaveAs Password:=iCost & cStrPassword, _
                           writeResPassword:=iCost & cStrPassword
                           
                 .Close True
              End With
            
        'Unlock all files in the folder
            Case Is = "UNLOCK"
              With ActiveWorkbook
                 .Unprotect iCost & cStrPassword
                 .Close True
              End With
            End Select
    '####################################################################################

    I have tried each of these and then both together. I'm sure I am close, but almost all websites are telling me the same thing, and that is what I am trying.
    Any guidance?

  4. #4
    Forum Contributor
    Join Date
    11-29-2016
    Location
    USA
    MS-Off Ver
    365
    Posts
    116

    Re: Add or Remove Passwords from Files

    I ended up getting the code to work.
    See the code below:

    Sub RemovePassword()
        ' Modified from a post from Stack
        ' https://stackoverflow.com/questions/53885596/remove-password-from-excel-files
        
        ' String Lists
        Const cStrExtensions As String = "*.xls*"
        Const cStrPassword As String = "*knights"
        
        Dim strFolderPath As String        ' Search Folder
        Dim strFileName As String        ' Current File Name (Workbook)
        Dim iCost       As Long
        Dim MyValue     As String
        Dim Response    As String
        Dim result      As String
        
        ' Confirm that the user wants to complete action
        If MsgBox("This action will Lock Or Unlock sensitive salary files, " & vbNewLine & _
        "Do you want To continue? ", vbCritical + vbYesNo, "WARNING") = vbYes Then
        
        ' Ask the user what they want to do, lock or unlock
        ' Display dialog box
    Again:
        MyValue = UCase(Application.InputBox(Prompt:="This action will Lock Or Unlock Salary files" & vbNewLine & _
                  "What would you Like To do, (L)ock Or (U)nlock?", Title:="WHAT CHA WANNA DO??"))
        
        ' Check if the user clicks cancel
        If TypeName(MyValue) = "Boolean" Then Exit Sub
        
        ' Need to work on this, enters an infinite loop if you don't enter a value
        Select Case Left(UCase(MyValue), 1)
            Case "L", "U"
            Case Else
                result = MsgBox("You only Have 2 Choices, Locked Or Unlocked", vbOKCancel)
                If result = 2 Then Exit Sub
                GoTo Again
        End Select
        
     
        With Application
            .ScreenUpdating = False
            .DisplayAlerts = False
            .EnableEvents = False
        End With
        
        With ThisWorkbook.ActiveSheet
            
            ' Choose Search Folder
            With Application.FileDialog(msoFileDialogFolderPicker)
                .Title = "Please Select the Folder With the Files"
                If .Show = False Then Exit Sub
                strFolderPath = .SelectedItems(1) & "\"
            End With
            
            ' Loop through folder to determine Current File Name (Workbook).
            strFileName = Dir(strFolderPath & cStrExtensions)
            
            ' Loop through files in folder.
            Do While strFileName <> ""
                
                ' Use the cost center as part of the password
                iCost = Trim(Left(strFileName, InStr(strFileName, " ") - 1))
                
                ' Open each file in folder
                ' Workbooks.Open strFolderPath & strFileName
                
                ' Debug.Print strFileName
                Workbooks.Open Filename:=strFolderPath & strFileName, _
                Password:=iCost & cStrPassword
                
                ' From this point on you are working with the departmental template
                
                Select Case MyValue
                    
                    ' LOCK all files in the folder
                    Case Is = "LOCK"
                        With ActiveWorkbook
                            ' Save file with password required to open and modify the file
                            .SaveAs Filename:=Application.ActiveWorkbook.FullName, Password:=iCost & cStrPassword, CreateBackup:=False
                            .Close True
                        End With
                        
                        Debug.Print "The following workbook has been Protected: " & strFileName
                        
                        ' UNLOCK all files in the folder
                        ' https://www.mrexcel.com/board/threads/remove-known-passwords-from-multiple-files-in-folder.1062378/
                    Case Is = "UNLOCK"
                        With ActiveWorkbook
                            .SaveAs Filename:=Application.ActiveWorkbook.FullName, Password:="", CreateBackup:=False
                            .Close
                        End With
                        Debug.Print "The following workbook has been Unprotected: " & strFileName
                        
                End Select
                
                strFileName = Dir()
                
                ' Exclude this workbook.
                If .Parent.Name = strFileName Then strFileName = Dir()
                
            Loop
            
        End With
        
    ProcedureExit:
        
        With Application
            .ScreenUpdating = True
            .DisplayAlerts = True
            .EnableEvents = True
        End With
        
        ' Exit if user clicks no
    Else
        MsgBox "D'OH!      ", vbInformation, "CHECK YA LATER!"
    End If
    Exit Sub
    
    ' Confirmation
    MsgBox "Success!       That's some good work ", vbInformation, "GREAT JOB"
    
    End Sub

  5. #5
    Forum Expert
    Join Date
    08-17-2007
    Location
    Poland
    Posts
    2,533

    Re: Add or Remove Passwords from Files

    Your code after the fix is pretty good, although you trusted me too much.
    For example. This condition will never be met:
    If TypeName(MyValue) = "Boolean" Then Exit Sub
    I wrote it wrong.

    This snippet won't necessarily work either:
                Select Case MyValue
                    
                    ' LOCK all files in the folder
                    Case Is = "LOCK"
    You mistakenly assumed that the user would type words in capital letters. And before that, you didn't convert user responses to uppercase.

    This code construction is very dangerous:
    With ActiveWorkbook
        .SaveAs Filename:= ...
        .Close
    End With
    The explanation is going to be a little tricky.
    Before explaining the problem with the cited code, you need to know what happens when you use SaveAs. This command saves the workbook under a new name, the "source" workbook is abandoned (closed without saving changes), and the active workbook is already a new instance of the "source" workbook.
    With ActiveWorkbook refers to the active workbook. And everything inside that construction refers to what comes after With, which is the "source" workbook.
    .SaveAs still refers to the correct workbook, but .Close does not. You are trying to close a workbook that is no longer there because it was abandoned when you saved it. But do not worry. You are not alone. Even though I know about this trap, I made this mistake a moment ago.

    Sometimes a folder may contain temporary files that are created when you open a particular workbook. After the file is properly closed, the temporary file is deleted by Excel. However, when a file is closed abruptly (due to a fatal error), the temporary file may remain on disk. They start with a tilde (~), but the file extension is the same as the actual file. Temporary files have a very different structure and you may get an error when you open them in Excel. When looping through files, exclude them.

    It's mine now.
    I don't trust the Dir() function, so I use File System Object. This makes the code longer. Besides, I like "rich" code. In addition, I pay more attention to the safe execution of the code. You can apply it, or you can stay with yours, provided that you correct the mistakes I mentioned.
    Sub ToggleProtectWorkbooks()
    
        Const cstrProcedure = "ToggleProtectWorkbooks"
        Const cstrPattern As String = "[!~]*.xls*" 'Excel files, no temp files
        Const cStrPassword As String = "*knights" 'The second part of password
    
        Dim strFolderPath As String     ' Search Folder
        Dim vFileName As Variant       ' Current File Name (Workbook)
        Dim varrList As Variant         ' Array of filtered files in a folder
        Dim vCost As Variant
        Dim iCost       As Long
        Dim MyValue     As String
        Dim Answer    As Variant
        Dim lAutoSecur As MsoAutomationSecurity
        Dim FSO As Object
    
        
    
        On Error GoTo HandleError
        
        lAutoSecur = Application.AutomationSecurity
    
      
        'Confirm that the user wants to complete action
        If MsgBox("This action will Lock or Unlock sensitive salary files, " & vbNewLine & _
                  "Do you want to continue? ", vbExclamation + vbYesNo + vbDefaultButton2, "WARNING") = vbYes Then
    
    
            'Ask the user what they want to do, lock or unlock
            ' Display dialog box
    TryAgain:
            Answer = UCase(InputBox(Prompt:="This action will Lock or Unlock Salary files" & vbNewLine & _
                                                         "What would you like to do, (L)ock or (U)nlock?", Title:="WHAT CHA WANNA DO??"))
    
            If Len(Trim(Answer)) = 0 Then Exit Sub
            
            'Take only the first letter of the answer
            MyValue = Left(UCase(Answer), 1)
            
            Select Case MyValue
                Case "L", "U"
                Case Else
                    MsgBox "You only Have 2 Choices, Locked or Unlocked", vbExclamation
                    GoTo TryAgain
            End Select
    
    
            ' Choose Search Folder
            With Application.FileDialog(msoFileDialogFolderPicker)
                If .Show = False Then Exit Sub
                strFolderPath = .SelectedItems(1) & "\"
            End With
            
            'Array of filtered files in a folder (Full paths)
            varrList = ArrayFiles(strFolderPath, cstrPattern)
            
            If UBound(varrList) < 0 Then
              MsgBox "No files found in the folder!", vbExclamation
              Exit Sub
            End If
    
            With Application
                .ScreenUpdating = False
                .DisplayAlerts = False
                'Disable macros in files you open
                .AutomationSecurity = msoAutomationSecurityForceDisable
            End With
            
            Set FSO = CreateObject("Scripting.FileSystemObject")
            
            ' Loop through the files in a folder.
            ' Use the cost center as part of the password
            For Each vFileName In varrList
              'The first word in file name before the space
              vCost = Split(Trim(GetFileNameFSO(CStr(vFileName), FSO)))(0)
              
              If IsNumeric(vCost) Then
                iCost = vCost
              
                SaveBookAndClose CStr(vFileName), iCost & cStrPassword, MyValue = "L"
                
                DoEvents
              Else
                Debug.Print "File skipped: " & vFileName
              End If
              
            Next vFileName
    
        Else
            MsgBox "D'OH!      ", vbInformation, "CHECK YA LATER!"
        End If
        
        MsgBox "Done"
    
    
    HandleExit:
            With Application
                .ScreenUpdating = True
                .DisplayAlerts = True
                .AutomationSecurity = lAutoSecur
            End With
        
            Set FSO = Nothing
        Exit Sub
    
    HandleError:
        MsgBox Err.Number & vbLf & Err.Description & vbLf & _
          "in: " & cstrProcedure, vbCritical, "Error"
        Resume HandleExit
    End Sub
    
    
    
    Sub SaveBookAndClose(sFileName As String, sPass As String, blnProtect As Boolean)
        Dim wkb As Workbook
        
        Set wkb = Workbooks.Open(Filename:=sFileName, Password:=sPass)
        
        wkb.SaveAs Filename:=sFileName, Password:=IIf(blnProtect = True, sPass, "")
        
        Set wkb = ActiveWorkbook
        wkb.Close False
    End Sub
    
    
    
    Function ArrayFiles(ByVal sFolder As String, Optional sFilter As String, Optional FSO As Object) As Variant
        Dim fsoFolder   As Object
        Dim fsoFile     As Object
        Dim i           As Long
        Dim oDic        As Object
        Dim IsNotFSO    As Boolean
        Dim objFSO      As Object
    
    
        Set objFSO = FSO
    
        If objFSO Is Nothing Then
            Set objFSO = CreateObject("Scripting.FileSystemObject")
            IsNotFSO = True
        End If
    
        Set oDic = CreateObject("Scripting.Dictionary")
    
    
        If objFSO.FolderExists(sFolder) Then
            Set fsoFolder = objFSO.GetFolder(sFolder)
    
    
            If Len(sFilter) = 0 Then sFilter = "*.*"
    
    
            For Each fsoFile In fsoFolder.Files
    
                If UCase(fsoFile.Name) Like UCase(sFilter) Then
                    oDic.Add fsoFile.Path, 0
                End If
    
            Next fsoFile
    
        End If
    
        Set fsoFolder = Nothing
    
        If IsNotFSO Then
            Set objFSO = Nothing
        End If
    
        ArrayFiles = oDic.Keys()
    
    End Function
    
    
    
    Function GetFileNameFSO(strFileFullPath As String, Optional FSO As Object) As String
        Dim IsNotFSO    As Boolean
        Dim objFSO      As Object
        Dim oFile       As Object
    
        Set objFSO = FSO
    
        If objFSO Is Nothing Then
            Set objFSO = CreateObject("Scripting.FileSystemObject")
            IsNotFSO = True
        End If
    
        If objFSO.FileExists(strFileFullPath) Then
            GetFileNameFSO = objFSO.GetFileName(strFileFullPath)
        End If
    
        If IsNotFSO Then
            Set objFSO = Nothing
        End If
    
    End Function
    Artik
    Last edited by Artik; 07-08-2021 at 09:59 PM.

  6. #6
    Forum Contributor
    Join Date
    11-29-2016
    Location
    USA
    MS-Off Ver
    365
    Posts
    116

    Re: Add or Remove Passwords from Files

    @Artik This is amazing!
    Its funny you should say that about your bit of code,
    If TypeName(MyValue) = "Boolean" Then Exit Sub
    I did have to work on it after I posted my "Solution". See below:

    Thank you very much for taking the time and effort to work this all out and for the concise explanation! Very much appreciated.
    I will take this all in. I find after I figure a bit of code out (or get the answer in this case) I can take the time to do a deeper learning dive.

    Thanks again,

    Joe

    Private Sub CommandButton1_Click()
    
    ' Modified from a post from Stack
        ' https://stackoverflow.com/questions/53885596/remove-password-from-excel-files
        
        ' String Lists
        Const cStrExtensions As String = "*.xls*"
        Const cStrPassword As String = "*knights"
        
        Dim strFolderPath As String        ' Search Folder
        Dim strFileName As String        ' Current File Name (Workbook)
        Dim iCost       As Long
        Dim MyValue     As Variant
        Dim Response    As String
        Dim result      As String
        
        ' Confirm that the user wants to complete action
        If MsgBox("This action will Lock Or Unlock sensitive salary files, " & vbNewLine & _
        "Do you want To continue? ", vbCritical + vbYesNo, "WARNING") = vbYes Then
        
        ' Ask the user what they want to do, lock or unlock
        ' Display dialog box
    
    Again:
        MyValue = UCase(Application.InputBox(Prompt:="This action will Lock Or Unlock Salary files" & vbNewLine & _
                  "What would you like to do, Lock Or Unlock?", Title:="WHAT CHA WANNA DO??"))
        
        
        ' Check if the user clicks cancel
        If MyValue = False Then Exit Sub
        
         'Want to test if user presses cancel or does not enter a value or enters an invalid value
        Select Case MyValue
            Case "LOCK", "UNLOCK"
                    GoTo Continue
            Case Else
                    result = MsgBox("You only Have 2 Choices, Locked Or Unlocked", vbOKCancel)
                    If result = "" Then
                        MsgBox "You Didn't enter a Valid Value!"
                        GoTo Again
                    If result = 2 Then Exit Sub
                End If
        End Select
    
    
    Continue:
    
        With Application
            .ScreenUpdating = False
            .DisplayAlerts = False
            .EnableEvents = False
        End With
        
        With ThisWorkbook.ActiveSheet
            
            ' Choose Search Folder
            With Application.FileDialog(msoFileDialogFolderPicker)
                .Title = "Please Select the Folder With the Files"
                If .Show = False Then Exit Sub
                strFolderPath = .SelectedItems(1) & "\"
            End With
            
            ' Loop through folder to determine Current File Name (Workbook).
            strFileName = Dir(strFolderPath & cStrExtensions)
            
            ' Loop through files in folder.
            Do While strFileName <> ""
                
                ' Use the cost center as part of the password
                iCost = Trim(Left(strFileName, InStr(strFileName, " ") - 1))
                
                ' Open each file in folder
                ' Workbooks.Open strFolderPath & strFileName
                
                ' Debug.Print strFileName
                Workbooks.Open Filename:=strFolderPath & strFileName, _
                Password:=iCost & cStrPassword
                
                ' From this point on you are working with the departmental template
                
                Select Case MyValue
                    
                    ' LOCK all files in the folder
                    Case Is = "LOCK"
                        With ActiveWorkbook
                            ' Save file with password required to open and modify the file
                            .SaveAs Filename:=Application.ActiveWorkbook.FullName, Password:=iCost & cStrPassword, CreateBackup:=False
                            .Close True
                        End With
                        
                        Debug.Print "The following workbook has been Protected: " & strFileName
                        
                        ' UNLOCK all files in the folder
                        ' https://www.mrexcel.com/board/threads/remove-known-passwords-from-multiple-files-in-folder.1062378/
                    Case Is = "UNLOCK"
                        With ActiveWorkbook
                            .SaveAs Filename:=Application.ActiveWorkbook.FullName, Password:="", CreateBackup:=False
                            .Close
                        End With
                        Debug.Print "The following workbook has been Unprotected: " & strFileName
                        
                End Select
                
                strFileName = Dir()
                
                ' Exclude this workbook.
                If .Parent.Name = strFileName Then strFileName = Dir()
                
            Loop
            
        End With
        
    ProcedureExit:
        
        With Application
            .ScreenUpdating = True
            .DisplayAlerts = True
            .EnableEvents = True
        End With
        
        ' Exit if user clicks no
    Else
        MsgBox "D'OH!      ", vbInformation, "CHECK YA LATER!"
    End If
    Exit Sub
    
    ' Confirmation
    MsgBox "Success!       That's some good work ", vbInformation, "GREAT JOB"
    
    End Sub

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 3
    Last Post: 02-08-2021, 06:56 PM
  2. [SOLVED] macro to remove worksheet-level passwords
    By DavidH in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 03-27-2013, 01:33 PM
  3. Autocomplete passwords to linked files
    By Brokovich in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-19-2007, 04:23 AM
  4. [SOLVED] I need to remove passwords from a list of files.
    By Conan Kelly in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-17-2005, 01:50 PM
  5. suppressing passwords to edit linked files
    By tjtjjtjt in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-13-2005, 09:05 PM
  6. [SOLVED] updateLink; files with passwords , VBA help!
    By tp in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-13-2005, 05:05 AM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1