Hello,

i have the file name stored in C2 and the file is already open. what would be the code to activate this file? i tried activating this by storing the cell value in a variable..but it does not work and gives me error message "Subscript out of range"

desfile = Workbooks("File1").Worksheets("Sheetname1").Range("c2").Value
    Workbook(desfile).Activate