There are different reasons possible. At first the path isn't always accessable and/or valid - maybe there is a blocking from your XAMPP environment or from windows (for example services like shadow copies - further I'm not sure if htdocs is a good folder for this). Also the object-caption could be contain invalid chars like '\'. Also a lack on free storage-space could be a reason.
Further if the security-settings from the modul has changed it will be fail.
I would put a ActiveDocument.WaitForIdle before the exporting-statement and use msgbox or an external logging for this routine - Re: export all objects to ppt - to know exactly what happens and would consider to implement an error-handler (on resume next, query the err.number (skipping, repeating, ...), react on this, on error goto 0).
Thank you for your reply.
I already checked most of those possibilities.
XAMPP is the PHP platorm i am using as a server and in order to publish php/html files. The reason it exports images to that file is in order to publish them and make them available.
I've already checked file/folder permissions and they always have disk space available, so that might not be the reason why sometimes it export, sometimes doesn't. Captions have "legal" characters, or else it would never work either.
In the vbscript I already have a WaitForIdle statement there. Where do you think I can incluse this, exactly? Somewhere in this vbsfile or inside the qlik doc?
I've also included a On Error Resume Next entry. So far, so errors, and intermitency still occurs.
I found the issue.
I was running an external job to fetch excel files and they were being synchronized periodically at the same time they were imported inside the qvw file. The simultaneous process might have caused this while the qvw was reloading. I have fixed it by using a bat to evoque first that excel download job and right after load and run the qvw file. It works perfectly now.