Beste kenners,
Ik heb 2 pagina`s vol met hyperlinks en laat ze door middel van een makro die ik heb opgenomen een voor een openen en afdrukken nu meer ik dat de bestanden niet volledig worden geladen is het mogelijk om een soort pauze tijd in te bouwen ?
de volgende makro gebruik ik
Private Sub frm1cmdverder_Click()
On Error GoTo foutje
Selection.GoTo What:=wdGoToBookmark, Name:="beginpunt"
Selection.MoveRight Unit:=wdCharacter, Count:=3
If frm1keus1 = True Then
Unload frm1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "tray3"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
herhalen:
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\ tray3"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
On Error GoTo foutje:
GoTo herhalen
Else
If frm1keus2 = True Then
Unload frm1
Selection.GoTo What:=wdGoToBookmark, Name:="beginpunt"
Selection.MoveRight Unit:=wdCharacter, Count:=3
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\C350 Wit"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
herhalen1:
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\C350 Wit"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
On Error GoTo foutje:
GoTo herhalen1
Else
If frm1keus3 = True Then
Unload frm1
Selection.GoTo What:=wdGoToBookmark, Name:="beginpunt"
Selection.MoveRight Unit:=wdCharacter, Count:=3
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\Tray 4"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
herhalen2:
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\Tray 4"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
On Error GoTo foutje:
GoTo herhalen2
Else
msgbox "geen printer gekozen"
Exit Sub
End If
End If
End If
foutje:
msgbox "klaar", vbInformation, "opdracht voltooid"
End Sub
Ik heb 2 pagina`s vol met hyperlinks en laat ze door middel van een makro die ik heb opgenomen een voor een openen en afdrukken nu meer ik dat de bestanden niet volledig worden geladen is het mogelijk om een soort pauze tijd in te bouwen ?
de volgende makro gebruik ik
Private Sub frm1cmdverder_Click()
On Error GoTo foutje
Selection.GoTo What:=wdGoToBookmark, Name:="beginpunt"
Selection.MoveRight Unit:=wdCharacter, Count:=3
If frm1keus1 = True Then
Unload frm1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "tray3"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
herhalen:
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\ tray3"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
On Error GoTo foutje:
GoTo herhalen
Else
If frm1keus2 = True Then
Unload frm1
Selection.GoTo What:=wdGoToBookmark, Name:="beginpunt"
Selection.MoveRight Unit:=wdCharacter, Count:=3
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\C350 Wit"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
herhalen1:
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\C350 Wit"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
On Error GoTo foutje:
GoTo herhalen1
Else
If frm1keus3 = True Then
Unload frm1
Selection.GoTo What:=wdGoToBookmark, Name:="beginpunt"
Selection.MoveRight Unit:=wdCharacter, Count:=3
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\Tray 4"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
herhalen2:
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActivePrinter = "\\Tray 4"
Application.printout FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
ManualDuplexPrint:=False, Collate:=True, Background:=True, PrintToFile:= _
False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActiveWindow.Close
On Error GoTo foutje:
GoTo herhalen2
Else
msgbox "geen printer gekozen"
Exit Sub
End If
End If
End If
foutje:
msgbox "klaar", vbInformation, "opdracht voltooid"
End Sub