Thread: Application
View Single Post
  #11   Report Post  
Posted to microsoft.public.excel.programming
Michael Michael is offline
external usenet poster
 
Posts: 791
Default Application

Hi Bob...

Jihaaa!!!!!

Yes, it works perfect. Thanks a lot!

I really appreciate your help.

Michael
--
Nil Satis Nisi Optimum


"Bob Phillips" wrote:

This also works

Private Sub Workbook_Open() 'This is part of the macro in workbook VT
Dim FileOpen, FileOpenend

FileOpen = ActiveWorkbook.Path
FileOpenend = FileOpen & "\Arkiv\" & "Statistikk.xls"

Workbooks.Open FileOpenend
Application.Windows("Statistikk.xls").Visible = False

End Sub

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Michael" wrote in message
...
Hi Bob.

This is the code:

Private Sub Workbook_Open() 'This is part of the macro in workbook VT

Fileopen = ActiveWorkbook.Path
Fileopenend = Fileopen & "\Arkiv\" & "Statistikk.xls"

Workbooks.Open Fileopenend

**Now the workbook Statistikk is open, but it will not take this

Windows("Statistikk.xls").Visible = False

End Sub


--
Nil Satis Nisi Optimum


"Bob Phillips" wrote:

Michael,

That seems to suggest then that you do not have a workbook called
"Statistikk.xls" open in Excel. Is it spelt correctly?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Michael" wrote in message
...
Hi again Bob.

I forgot to tell you that i tried this one to.

Windows("Statistikk.xls").Visible = False

The message i get is "Run time error 9" "subscript out of range"
--
Nil Satis Nisi Optimum


"Bob Phillips" wrote:

Almost Michael, when I say workbook name I mean with the extension

Windows("Statistikk.xls").Visible = False


--

HTH

RP
(remove nothere from the email address if mailing direct)