|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Simple WebDAV Questioncould be my first mistake, but I digress. Anyway, I can loop through these emails and once I'm done with them I want to move them to a folder called Processed. However, these emails sometimes have the same "URL" beyond the folder name. Trivial, non-real example: http://exchangeserverhere.com/Inbox/whatever.eml http://exchangeserverhere.com/Processed/whatever.eml It seems the "URL"s are defined by the email subject, so when I try to move the mail from the Inbox to the Processed folder, I'll end up with a Precondition Failed (412) unless I don't set the overwrite header to F. But that seems foolish, because I don't want to lose the email that was already in "Processed". Basically I want to perform the exact same operation as dragging the email in Outlook from one folder to another. How do I replicate this? Thanks Just make sure that you create a unique URL each time. If you change
the URL, it doesn't affect the dislayed subject at all. You could try getting the subject, and then add the current date and time to it, and a random number just to be on the safe side: /Processed/whatever-20070329-163125-85627.eml I personally don't even bother with the subject part, and have never noticed any unpleasant side effects. Lee. -- Show quote_______________________________________ Outlook Web Access For PDA , OWA For WAP www.owapda.com email a@t leederbyshire d.0.t c.0.m _______________________________________ "James" <minork***@gmail.com> wrote in message F. Butnews:%23RWkFRhcHHA.3408@TK2MSFTNGP03.phx.gbl... > Using WebDAV to parse emails from a mailbox on an exchange server. This > could be my first mistake, but I digress. Anyway, I can loop through these > emails and once I'm done with them I want to move them to a folder called > Processed. However, these emails sometimes have the same "URL" beyond the > folder name. Trivial, non-real example: > > http://exchangeserverhere.com/Inbox/whatever.eml > > http://exchangeserverhere.com/Processed/whatever.eml > > It seems the "URL"s are defined by the email subject, so when I try to move > the mail from the Inbox to the Processed folder, I'll end up with a > Precondition Failed (412) unless I don't set the overwrite header to Show quote > that seems foolish, because I don't want to lose the email that was already > in "Processed". Basically I want to perform the exact same operation as > dragging the email in Outlook from one folder to another. How do I > replicate this? > > Thanks > > Ah, very interesting. I didn't know that. I'm also noticing now that
there's an "Allow-rename" header. I think this may do what I'm looking for automatically, although I'm not certain and there doesn't seem to be much info out there. Thanks for your help. Show quote "Lee Derbyshire [MVP]" <email a@t leederbyshire d.0.t c.0.m> wrote in message news:eiXkBehcHHA.4632@TK2MSFTNGP03.phx.gbl... > > Just make sure that you create a unique URL each time. If you change > the URL, it doesn't affect the dislayed subject at all. You could try > getting the subject, and then add the current date and time to it, and > a random number just to be on the safe side: > > /Processed/whatever-20070329-163125-85627.eml > > I personally don't even bother with the subject part, and have never > noticed any unpleasant side effects. > > Lee. > > > -- > _______________________________________ > > Outlook Web Access For PDA , OWA For WAP > www.owapda.com > email a@t leederbyshire d.0.t c.0.m > _______________________________________ > > "James" <minork***@gmail.com> wrote in message > news:%23RWkFRhcHHA.3408@TK2MSFTNGP03.phx.gbl... >> Using WebDAV to parse emails from a mailbox on an exchange server. > This >> could be my first mistake, but I digress. Anyway, I can loop > through these >> emails and once I'm done with them I want to move them to a folder > called >> Processed. However, these emails sometimes have the same "URL" > beyond the >> folder name. Trivial, non-real example: >> >> http://exchangeserverhere.com/Inbox/whatever.eml >> >> http://exchangeserverhere.com/Processed/whatever.eml >> >> It seems the "URL"s are defined by the email subject, so when I try > to move >> the mail from the Inbox to the Processed folder, I'll end up with a >> Precondition Failed (412) unless I don't set the overwrite header to > F. But >> that seems foolish, because I don't want to lose the email that was > already >> in "Processed". Basically I want to perform the exact same > operation as >> dragging the email in Outlook from one folder to another. How do I >> replicate this? >> >> Thanks >> >> > > I've never heard of 'Allow-rename'. Try it out on something that you don't
mind losing, though, first. Show quote "James" <minork***@gmail.com> wrote in message news:OOw$BvhcHHA.3484@TK2MSFTNGP04.phx.gbl... > Ah, very interesting. I didn't know that. I'm also noticing now that > there's an "Allow-rename" header. I think this may do what I'm looking > for automatically, although I'm not certain and there doesn't seem to be > much info out there. > > Thanks for your help. > > "Lee Derbyshire [MVP]" <email a@t leederbyshire d.0.t c.0.m> wrote in > message news:eiXkBehcHHA.4632@TK2MSFTNGP03.phx.gbl... >> >> Just make sure that you create a unique URL each time. If you change >> the URL, it doesn't affect the dislayed subject at all. You could try >> getting the subject, and then add the current date and time to it, and >> a random number just to be on the safe side: >> >> /Processed/whatever-20070329-163125-85627.eml >> >> I personally don't even bother with the subject part, and have never >> noticed any unpleasant side effects. >> >> Lee. >> >> >> -- >> _______________________________________ >> >> Outlook Web Access For PDA , OWA For WAP >> www.owapda.com >> email a@t leederbyshire d.0.t c.0.m >> _______________________________________ >> >> "James" <minork***@gmail.com> wrote in message >> news:%23RWkFRhcHHA.3408@TK2MSFTNGP03.phx.gbl... >>> Using WebDAV to parse emails from a mailbox on an exchange server. >> This >>> could be my first mistake, but I digress. Anyway, I can loop >> through these >>> emails and once I'm done with them I want to move them to a folder >> called >>> Processed. However, these emails sometimes have the same "URL" >> beyond the >>> folder name. Trivial, non-real example: >>> >>> http://exchangeserverhere.com/Inbox/whatever.eml >>> >>> http://exchangeserverhere.com/Processed/whatever.eml >>> >>> It seems the "URL"s are defined by the email subject, so when I try >> to move >>> the mail from the Inbox to the Processed folder, I'll end up with a >>> Precondition Failed (412) unless I don't set the overwrite header to >> F. But >>> that seems foolish, because I don't want to lose the email that was >> already >>> in "Processed". Basically I want to perform the exact same >> operation as >>> dragging the email in Outlook from one folder to another. How do I >>> replicate this? >>> >>> Thanks >>> >>> >> >> > > > Hello,
when the allow-rename header is set, exchange will append a -2, -3, etc. to the relative name of the item to make it unique. If allow-rename and overwrite is false, the operation fails. Best regards, Henning Krause Show quote "Lee Derbyshire [MVP]" <email a@t leederbyshire d.0.t c.0.m> wrote in message news:O5%23%23HRjcHHA.5052@TK2MSFTNGP05.phx.gbl... > > I've never heard of 'Allow-rename'. Try it out on something that you > don't mind losing, though, first. > > > "James" <minork***@gmail.com> wrote in message > news:OOw$BvhcHHA.3484@TK2MSFTNGP04.phx.gbl... >> Ah, very interesting. I didn't know that. I'm also noticing now that >> there's an "Allow-rename" header. I think this may do what I'm looking >> for automatically, although I'm not certain and there doesn't seem to be >> much info out there. >> >> Thanks for your help. >> >> "Lee Derbyshire [MVP]" <email a@t leederbyshire d.0.t c.0.m> wrote in >> message news:eiXkBehcHHA.4632@TK2MSFTNGP03.phx.gbl... >>> >>> Just make sure that you create a unique URL each time. If you change >>> the URL, it doesn't affect the dislayed subject at all. You could try >>> getting the subject, and then add the current date and time to it, and >>> a random number just to be on the safe side: >>> >>> /Processed/whatever-20070329-163125-85627.eml >>> >>> I personally don't even bother with the subject part, and have never >>> noticed any unpleasant side effects. >>> >>> Lee. >>> >>> >>> -- >>> _______________________________________ >>> >>> Outlook Web Access For PDA , OWA For WAP >>> www.owapda.com >>> email a@t leederbyshire d.0.t c.0.m >>> _______________________________________ >>> >>> "James" <minork***@gmail.com> wrote in message >>> news:%23RWkFRhcHHA.3408@TK2MSFTNGP03.phx.gbl... >>>> Using WebDAV to parse emails from a mailbox on an exchange server. >>> This >>>> could be my first mistake, but I digress. Anyway, I can loop >>> through these >>>> emails and once I'm done with them I want to move them to a folder >>> called >>>> Processed. However, these emails sometimes have the same "URL" >>> beyond the >>>> folder name. Trivial, non-real example: >>>> >>>> http://exchangeserverhere.com/Inbox/whatever.eml >>>> >>>> http://exchangeserverhere.com/Processed/whatever.eml >>>> >>>> It seems the "URL"s are defined by the email subject, so when I try >>> to move >>>> the mail from the Inbox to the Processed folder, I'll end up with a >>>> Precondition Failed (412) unless I don't set the overwrite header to >>> F. But >>>> that seems foolish, because I don't want to lose the email that was >>> already >>>> in "Processed". Basically I want to perform the exact same >>> operation as >>>> dragging the email in Outlook from one folder to another. How do I >>>> replicate this? >>>> >>>> Thanks >>>> >>>> >>> >>> >> >> >> > > |
|||||||||||||||||||||||