Hiding two columns
Hi Cam
I answered a similar question for you last week.
This code does what you want and you can put it in any workbook to run
it from.
Good luck with this.
Marcus
Sub OpenFiles()
Dim wkbk As Workbook
Dim Lw As Integer, Sr As Integer
With Application.FileSearch
.NewSearch
.LookIn = "c:\Test"
.SearchSubFolders = False
.Filename = ".xls"
.FileType = msoFileTypeExcelWorkbooks
If .Execute() 0 Then
For i = 1 To .FoundFiles.Count
Set wkbk = Workbooks.Open(.FoundFiles(i))
Columns("K:L").Insert
wkbk.Close SaveChanges:=True
Next i
End If
End With
End Sub
|