Avatar billede hjbe Nybegynder
11. november 2002 - 20:07 Der er 9 kommentarer og
1 løsning

Batch print til Acrobat Reader

Jeg har fået Acrobat Reader til at modtage de filer jeg sender til dem fra Access.
Men når jeg sender flere end 1 fil i et loop forsvinder de næste.
Jeg har prøvet at sætte en ventefunktion ind. Se
http://www.mvps.org/access/api/api0004.htm

Jeg bruger den sådan her

Set dbs = CurrentDb
Set rst = dbs.OpenRecordset("tblPrint", dbOpenDynaset)
Do While Not rst.EOF
sti = rst!Path
docname = "C:\Program Files\Adobe\Acrobat 4.0\reader\AcroRd32.exe /t" & " " & sti & " " & "\\bergmann\brother"
Call ShellWait(docname, 0)
rst.MoveNext
Loop
rst.Close
dbs.Close
Set rst = Nothing
Set dbs = Nothing

Er der nogen der kender den, og ved hvad jeg gør galt ?
Avatar billede terry Ekspert
11. november 2002 - 21:15 #1
WHERE do you append the name of the file?
Avatar billede terry Ekspert
11. november 2002 - 21:16 #2
shouldnt it be

docname = "C:\Program Files\Adobe\Acrobat 4.0\reader\AcroRd32.exe /t" & " " & "\\bergmann\brother\" & sti
Avatar billede hjbe Nybegynder
12. november 2002 - 09:19 #3
No, if you look at this link
http://support.adobe.com/devsup/devsup.nsf/docs/51412.htm

It works fine for the first print, but the Shellwait stops after printing the first one.
It seems it locks the AcroRd32 process. It is surposed to wait untill the jobs finished and then move one through the loop.
Avatar billede terry Ekspert
12. november 2002 - 09:26 #4
Yes I can see it should work. Does Acrobat get closed once the frist file is printed? If not then this is maybe what is wrong.
Avatar billede hjbe Nybegynder
12. november 2002 - 09:47 #5
No, it looks like it is the Shellwait module that keeps the Acrobat in process.
If I remove the the Call Shellwait and just use the Call Shell the Acrobat shuts down after the first print, but then I only get that one. The Loop runs on and the rest of the prints dissapears. I need to stop the loop untill Acrobat has finshed the first print, before it moves on.

Question, are you the Terry Kreft who wrote the
http://www.mvps.org/access/api/api0004.htm
Avatar billede terry Ekspert
12. november 2002 - 13:03 #6
No its not me.

Dont know what to suggest,sorry!
Avatar billede hjbe Nybegynder
12. november 2002 - 13:59 #7
OK, Thank you anyway.
I'll just have to try something else
Avatar billede terry Ekspert
22. november 2002 - 15:38 #8
are we going to close here?
Avatar billede hjbe Nybegynder
22. november 2002 - 17:16 #9
yes, I have'nt found any solution yet, Points to you for trying
Avatar billede terry Ekspert
25. november 2002 - 08:43 #10
thanks :o)
Avatar billede Ny bruger Nybegynder

Din løsning...

Tilladte BB-code-tags: [b]fed[/b] [i]kursiv[/i] [u]understreget[/u] Web- og emailadresser omdannes automatisk til links. Der sættes "nofollow" på alle links.

Loading billede Opret Preview
Kategori
Dyk ned i databasernes verden på et af vores praksisnære Access-kurser

Log ind eller opret profil

Hov!

For at kunne deltage på Computerworld Eksperten skal du være logget ind.

Det er heldigvis nemt at oprette en bruger: Det tager to minutter og du kan vælge at bruge enten e-mail, Facebook eller Google som login.

Du kan også logge ind via nedenstående tjenester