PrintOut workSheet

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all,
in the following code
....
activeWorkbook.WorkSheets.Item(activeWorkbook.WorkSheets.Cout).PrinOut
....
Nothing happen, i.e No print out produced !
But when changed for example to :
....
activeWorkbook.WorkSheets.Item(4).PrintOut
.....
Things work fine , i.e the print will be produced
any explanation and help please.
thanks
 
well, I know nothing about VBA, but I did notice that "cout" needs an
and "prinOut" needs a t. Also, should there be a space between Wor
and Sheets? I'm just asking, like I said, I don't know much about thi
stuff. So maybe make it look like this?

activeWorkbook.WorkSheets.Item(activeWorkbook.WorkSheets.Count).PrintOu
 
thanks, DKy for your observations
But in my actual coding
typing was ok no errors, count with "n" and PrintOut with "t" and there
should be no space in worksheets
thanks again.
 
DKY,

i think my problem was to add the new sheet (which to be printed )
to the end i.e to the right of list, so that's what i did

dim Nsht as worksheet
if Nsht is Nothing Then
worksheets.add after:= Worksheets(Worksheets.count)
end if

.....The rest of coding for printing just worked fine
thanks DKY, any further thoughts are welcome
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top