![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
Hi All,
I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
Ads |
#2
|
|||
|
|||
![]()
Are you sure the file name does not contain any invalid (":", etc)
characters? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Hi All, I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
#3
|
|||
|
|||
![]()
Yes,
strFilename = "c\temp\ddmmyy.rtf" Failing that is there another way save documents to a particular location that won't error out ? Regards Justin "Dmitry Streblechenko" wrote: Are you sure the file name does not contain any invalid (":", etc) characters? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Hi All, I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
#4
|
|||
|
|||
![]()
Do check the attachment type to make suree you are only working with the
regular by-valuee attachments Is it possible that some other app already has that file open? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Yes, strFilename = "c\temp\ddmmyy.rtf" Failing that is there another way save documents to a particular location that won't error out ? Regards Justin "Dmitry Streblechenko" wrote: Are you sure the file name does not contain any invalid (":", etc) characters? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Hi All, I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
#5
|
|||
|
|||
![]()
At this stage in the code, only outlook is running. It is after this point
that i call word to open the file from the nominated directory. It doesn't matter where i nominate the save location the problem seems to be the same ie it goes through the motion of saving - but it doesn't. The fact this worked perfectly for the past 12 months before and was still working up until the other morning, makes me wonder if it is failing due to an update from microsoft(i can't see how). But this doesn't seem right either as the code works perfectly on an identical machine not more than 6 feet away from it. Any thoughts Regards Justin "Dmitry Streblechenko" wrote: Do check the attachment type to make suree you are only working with the regular by-valuee attachments Is it possible that some other app already has that file open? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Yes, strFilename = "c\temp\ddmmyy.rtf" Failing that is there another way save documents to a particular location that won't error out ? Regards Justin "Dmitry Streblechenko" wrote: Are you sure the file name does not contain any invalid (":", etc) characters? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Hi All, I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
#6
|
|||
|
|||
![]()
Hmmm... Other than space aliens trying to play their games....
You do have the error handling on (i.e. no "on error resume next"), right? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... At this stage in the code, only outlook is running. It is after this point that i call word to open the file from the nominated directory. It doesn't matter where i nominate the save location the problem seems to be the same ie it goes through the motion of saving - but it doesn't. The fact this worked perfectly for the past 12 months before and was still working up until the other morning, makes me wonder if it is failing due to an update from microsoft(i can't see how). But this doesn't seem right either as the code works perfectly on an identical machine not more than 6 feet away from it. Any thoughts Regards Justin "Dmitry Streblechenko" wrote: Do check the attachment type to make suree you are only working with the regular by-valuee attachments Is it possible that some other app already has that file open? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Yes, strFilename = "c\temp\ddmmyy.rtf" Failing that is there another way save documents to a particular location that won't error out ? Regards Justin "Dmitry Streblechenko" wrote: Are you sure the file name does not contain any invalid (":", etc) characters? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Hi All, I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
#7
|
|||
|
|||
![]()
Unfortunately is suspect the problem is one that is not going to be easily
resolved. In this situation i can't resume on next as the next stage of the code relies on the fact that the rtf file has been saved in the nominated location. I will keep looking.... Many thanks for your help. I suspect it will be something that will right it self again as it just stopped working. Regards Justin "Dmitry Streblechenko" wrote: Hmmm... Other than space aliens trying to play their games.... You do have the error handling on (i.e. no "on error resume next"), right? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... At this stage in the code, only outlook is running. It is after this point that i call word to open the file from the nominated directory. It doesn't matter where i nominate the save location the problem seems to be the same ie it goes through the motion of saving - but it doesn't. The fact this worked perfectly for the past 12 months before and was still working up until the other morning, makes me wonder if it is failing due to an update from microsoft(i can't see how). But this doesn't seem right either as the code works perfectly on an identical machine not more than 6 feet away from it. Any thoughts Regards Justin "Dmitry Streblechenko" wrote: Do check the attachment type to make suree you are only working with the regular by-valuee attachments Is it possible that some other app already has that file open? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Yes, strFilename = "c\temp\ddmmyy.rtf" Failing that is there another way save documents to a particular location that won't error out ? Regards Justin "Dmitry Streblechenko" wrote: Are you sure the file name does not contain any invalid (":", etc) characters? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Hi All, I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
#8
|
|||
|
|||
![]()
I wasn't suggesting that you use "on error resume next", but just the
opposite - making sure you don' use it so you can see all the errors raised. Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Unfortunately is suspect the problem is one that is not going to be easily resolved. In this situation i can't resume on next as the next stage of the code relies on the fact that the rtf file has been saved in the nominated location. I will keep looking.... Many thanks for your help. I suspect it will be something that will right it self again as it just stopped working. Regards Justin "Dmitry Streblechenko" wrote: Hmmm... Other than space aliens trying to play their games.... You do have the error handling on (i.e. no "on error resume next"), right? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... At this stage in the code, only outlook is running. It is after this point that i call word to open the file from the nominated directory. It doesn't matter where i nominate the save location the problem seems to be the same ie it goes through the motion of saving - but it doesn't. The fact this worked perfectly for the past 12 months before and was still working up until the other morning, makes me wonder if it is failing due to an update from microsoft(i can't see how). But this doesn't seem right either as the code works perfectly on an identical machine not more than 6 feet away from it. Any thoughts Regards Justin "Dmitry Streblechenko" wrote: Do check the attachment type to make suree you are only working with the regular by-valuee attachments Is it possible that some other app already has that file open? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Yes, strFilename = "c\temp\ddmmyy.rtf" Failing that is there another way save documents to a particular location that won't error out ? Regards Justin "Dmitry Streblechenko" wrote: Are you sure the file name does not contain any invalid (":", etc) characters? Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool "Justin" wrote in message ... Hi All, I have an issue with one of my users in relation to some code that gets run in outlook. Basically the code reads the subject line and then saves the attachment to the "c:\temp\" directory on the users machine. The problem is that the code will work flawlessly on any other machine - ie it will save an attachment to "C:\temp\ddmmyyhhmm.rtf". For some reason it says it has saved the file, but when you check it is not there. I could run the code 100 times a day and it will work 92 times without an issue and the file is saved in the temp directory, the other 8 times it will not be there. I can trap the error without an issue but i don't see why it won't see the drive. Any thoughts - or is this one of those quirky things that just happens. TIA Justin |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
script the save of multiple attachments with the same name! | sumGirl | Outlook - General Queries | 1 | April 28th 06 10:03 AM |
Attachments won't open, save or copy | Bobk | Outlook Express | 4 | April 21st 06 03:54 PM |
Set Outlook to NOT save attachments in Sent Items? | [email protected] | Outlook - General Queries | 1 | March 9th 06 02:16 AM |
Express will not save or open attachments | N. B. | Outlook Express | 1 | March 7th 06 10:53 PM |
save attachments | NascarDude | Outlook Express | 2 | February 12th 06 10:36 PM |