Maybe somebody can help me too!
I have the following macro to print on letterhead and then on blank paper
with a header, then I delete the header and close. It works with all my
templates except for one and gives me above error!!!???
Sub UdskrivAlt()
'
' UdskrivAlt Makro
' Udskriver Original, SAGS-KOPI
'
If ActiveWindow.View.SplitSpecial = wdPaneNone Then
ActiveWindow.ActivePane.View.Type = wdPageView
Else
ActiveWindow.View.Type = wdPageView
End If
With ActiveDocument.PageSetup
.FirstPageTray = wdPrinterMiddleBin
.OtherPagesTray = wdPrinterMiddleBin
End With
ActiveDocument.PrintOut
With ActiveDocument.PageSetup
.FirstPageTray = wdPrinterDefaultBin
.OtherPagesTray = wdPrinterDefaultBin
End With
ActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeader
Selection.Font.Bold = wdToggle
Selection.ParagraphFormat.Alignment = wdAlignParagraphCenter
Selection.TypeText Text:="SAGS-KOPI"
ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument
ActiveDocument.PrintOut
ActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeader
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
Selection.Delete Unit:=wdCharacter, Count:=1
ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument
End Sub
Can anybody help me please!!! I have seen Neil Shepherd's suggestions but I
do not know where to insert!! I x my fingers!!
Regards
Bodiller
"Mike DiCanio" skrev:
> Neil,
>
[quoted text clipped - 48 lines]
> >
> > Good luck anyway.
Doug Robbins - 28 Jun 2005 22:25 GMT
And what line of code is highlighted when you click on debug?

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
> Maybe somebody can help me too!
>
[quoted text clipped - 103 lines]
>> >
>> > Good luck anyway.
Bodiller - 29 Jun 2005 08:34 GMT
Hi,
ALWAYS the first line after "With ActiveDocument.PageSetup"
Can you possibly help me!!
Regards
Bodiller
"Doug Robbins" skrev:
> And what line of code is highlighted when you click on debug?
>
[quoted text clipped - 105 lines]
> >> >
> >> > Good luck anyway.
Doug Robbins - 29 Jun 2005 21:19 GMT
The first or the second one?
I'm guessing it is the second and it is falling over because Word is still
printing the document. If that is the case, you should be able to overcome
it by using
ActiveDocument.PrintOut Background = False

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
> Hi,
> ALWAYS the first line after "With ActiveDocument.PageSetup"
[quoted text clipped - 118 lines]
>> >> >
>> >> > Good luck anyway.
Bodiller - 30 Jun 2005 16:26 GMT
Dear Doug,
When I saw your suggestions I was soooo happy!
Well, it always stops at the FIRST one!
I have tried to insert as per your suggestion - first at the first
ACTIVEDOCUMENT.PRINTOUT - did not work. Then added to the second - but
that did not help either!!
Any other suggestions???????
Regards
Bodiller
"Doug Robbins" skrev:
> The first or the second one?
>
[quoted text clipped - 126 lines]
> >> >> >
> >> >> > Good luck anyway.