View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
Jacob Skaria Jacob Skaria is offline
external usenet poster
 
Posts: 8,520
Default make workbook visible

I didnt get you..Try opening those workbooks again manually..

If this post helps click Yes
---------------
Jacob Skaria


"Seeker" wrote:

Hi Jacob,
The closed workbooks still invisible?
Rgds

"Jacob Skaria" wrote:

The code is to be placed within the BeforeClose event of your workbook.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
Dim wb As Workbook
For Each wb In Workbooks
If wb.Name < ThisWorkbook.Name Then wb.Close False
Next
End Sub

If this post helps click Yes
---------------
Jacob Skaria


"Jacob Skaria" wrote:

Try the below

Dim wb As Workbook
For Each wb In Workbooks
If wb.Name < ThisWorkbook.Name Then wb.Close False
Next

If this post helps click Yes
---------------
Jacob Skaria


"Seeker" wrote:

Dear All,
Some files are opened under ActiveWindow.Visible = False when a master file
opened, a small code is needed to be placed in the Workbook_BeforeClose to
check if any invisible file(s) still open, if yes, make invisible file(s) be
visible and close file(s). A thread has mentioned by using
Windows(€śfile.xls€ť).Visible = True, how should I do that please?
Regards