Opening Attachments from Outlook sometimes Read-Only

  • Thread starter Andrew Fiddian-Green
  • Start date
A

Andrew Fiddian-Green

When you open attachment files from Outlook it actually creates two
temporary images of the respective file in the OutlookSecureTempFolder
having names like the following:

Filename.Ext
Filename (2).Ext

And depending on the method of opening the attachment one or other of these
images is passed to the target application as follows:

- Double click from Viewing pane
=> passes Filename (2).Ext to the target application

- Double click from an open e-mail
=> passes Filename.Ext to the target application

- Drag and Drop (from either source)
=> uses OLE DnD to pass an IStream (with the name Filename.Ext)

The odd thing is that, on one of my machines Filename.Ext has read/write
permissions and Filename (2).Ext is read-only, whereas on another machine
both Filename.Ext and Filename (2).Ext have read/write permissions.

Questions: what is the purpose of this difference? and why is there a
difference in behaviour between the two machines?

AndrewFG
 
R

Roady [MVP]

Somewhere you went wrong with your testing.

Opening an attachment from Outlook will only create one file in the
OutlookSecureTempFolder with either the Read Only file attribute (not
permissions!) on or off depending if the message was open or not. If the
message wasn't opened first Outlook cannot track and store changes (you made
to the attachment) within the message and therefor it creates the file with
the Read Only file attribute on.

Only when you open the attachment for a second time (2) is added to the
filename.
 
A

Andrew Fiddian-Green

Robert, thanks for the feedback.
Opening an attachment from Outlook will only create one file in the
OutlookSecureTempFolder

Yes, you are right on this. My mistake.
If the message wasn't opened first Outlook cannot track and store changes
within the message and therefor it creates the file with the Read Only
file attribute on.


Ok. Now this part is clear to me. Thanks.
with either the Read Only file attribute on or off depending if the
message was open or not.

I don't agree. For example, on the machine on which I am writing this, the
Read Only file attribute is off in BOTH cases (so as you say, in one case
"Outlook cannot track and store changes). However on my other machine the
behaviour indeed matches your statement above. => Why would this be?

Regards,
AndrewFG
 
R

Roady [MVP]

What version(s) of Outlook are you using?
What type of attachments are you opening?

You might want to clear the OutlookSecureTempFolder first to do some clean
testing.

--
Robert Sparnaaij [MVP-Outlook]
Coauthor, Configuring Microsoft Outlook 2003


-----
 
A

Andrew Fiddian-Green

What version(s) of Outlook are you using?


Outlook 2003 11.8118.8132 SP2
What type of attachments are you opening?

The attachments are for an own application of mine. It has with a custom
file extension with an association in HKCR pointing to the application
concerned. And the application has entries in HKCR for both
\shell\open\command and \shell\open\ddeexec to forward the file to the
application a) when it is not running (via a command line parameter), and b)
when it is already running (via DDE)...
You might want to clear the OutlookSecureTempFolder first to do some clean
testing.

I did. It is completely empty before starting Outlook. And (even) empty once
Outlook has closed...

AndrewFG
 
R

Roady [MVP]

Checked the behavior with a regular doc-file already? ;-)

--
Robert Sparnaaij [MVP-Outlook]
Coauthor, Configuring Microsoft Outlook 2003


-----
 
A

Andrew Fiddian-Green

Checked the behavior with a regular doc-file already? ;-)

Well no actually. (??) Why would the type of file (i.e. file extension)
affect Outlook's behaviour concerning the read only flag?

AndrewFG
 
R

Roady [MVP]

It's not so much about Outlook applying a different logic to a different
extension but more about what your personalized extension does. And with
tracking issues it is always good to check if the behavior is consistent.

--
Robert Sparnaaij [MVP-Outlook]
Coauthor, Configuring Microsoft Outlook 2003


-----
 
A

Andrew Fiddian-Green

It's not so much about Outlook applying a different logic to a different
extension but more about what your personalized extension does. And with
tracking issues it is always good to check if the behavior is consistent.

Well interestingly with .doc files when the file is opened from the viewing
pane, Outlook creates one attachment with read only flag (on this machine at
least) and when it is opened from an open e-mail it creates two attachments
one with read only and one not. So the behaviour (at least on this machine)
is actually as I stated in the OP.

AndrewFG
 
D

Denny

Hello,

did you got a solution for the problem with write protection.
I have one computer doing so too with outlook 2002.

Denny
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top