Gif access is denied?

G

Guest

Ever heard of windows denying access to filenames? Not specific types, not
dangerous files, not secured files, but filenames.

Any file on my computer that ends in .gif gives the message "Access is
denied." when I try to open it. If I rename the file to .jpg or something
else, it opens fine (though that's not a good thing to do, obviously). Any
other image file opens fine, and if I rename one of them to .gif and try to
open it, I get "Access is denied."
And it's not just image files. Any file that opens with no problem, when
renamed to .gif and opened, results in "Access is denied."

How do I fix this?
 
G

Ground Cover

1. A .gif file should be accessible. Check the files association for the
..gif extension under the "Files Types" tab of "Folder Options" found in
"Control Panel".

2. Yes, there's a set of filenames that are reserved in Windows:

"Do not use the following reserved device names for the name of a file: CON,
PRN, AUX, NUL, COM1, COM2, COM3, COM4, COM5, COM6, COM7, COM8, COM9, LPT1,
LPT2, LPT3, LPT4, LPT5, LPT6, LPT7, LPT8, and LPT9. Also avoid these names
followed by an extension, for example, NUL.tx7.

Windows NT: CLOCK$ is also a reserved device name."


[Naming a File - MSDN]
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/fs/naming_a_file.asp
 
P

Patrick

1. File association is as it should be - it opens the gif editor. The
problem is when the gif editor (Photo Editor, Paint, etc..) tries to open
that file, it fails because windows suddenly denies access. I can request it
from within the program, and the previewer will display it.
Here's what I've got in file association (a lot of this is defaults)

[HKEY_CLASSES_ROOT\.gif]
"PerceivedType"="image"
@="giffile"
"Content Type"="image/gif"

[HKEY_CLASSES_ROOT\.gif\OpenWithProgids]
"giffile"=hex(0):

[HKEY_CLASSES_ROOT\.gif\PersistentHandler]
@="{098f2470-bae0-11cd-b579-08002b30bfeb}"

[HKEY_CLASSES_ROOT\giffile]
@="GIF Image"
"BrowserFlags"=dword:00000008
"EditFlags"=dword:00010000
"FriendlyTypeName"=hex(2):40,00,25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,\
00,6f,00,6f,00,74,00,25,00,5c,00,73,00,79,00,73,00,74,00,65,00,6d,00,33,00,\
32,00,5c,00,73,00,68,00,69,00,6d,00,67,00,76,00,77,00,2e,00,64,00,6c,00,6c,\
00,2c,00,2d,00,33,00,30,00,32,00,00,00
"ImageOptionFlags"=dword:00000003

[HKEY_CLASSES_ROOT\giffile\CLSID]
@="{25336920-03F9-11cf-8FD0-00AA00686F13}"

[HKEY_CLASSES_ROOT\giffile\DefaultIcon]
@="shimgvw.dll,2"

[HKEY_CLASSES_ROOT\giffile\shell]
@="Edit"

[HKEY_CLASSES_ROOT\giffile\shell\Edit]

[HKEY_CLASSES_ROOT\giffile\shell\Edit\command]
@="\"D:\\Program Files\\photoed\\PhotoEd.exe\" %1"

[HKEY_CLASSES_ROOT\giffile\shell\open]
@="Animate"

[HKEY_CLASSES_ROOT\giffile\shell\open\command]
@="\"D:\\Program Files\\msgif\\GIFAnimator.exe\" \"%1\""

[HKEY_CLASSES_ROOT\giffile\shell\open\ddeexec]

[HKEY_CLASSES_ROOT\giffile\shell\open\ddeexec\Application]
@="shimgvw"

[HKEY_CLASSES_ROOT\giffile\shell\open\ddeexec\Topic]
@="System"

[HKEY_CLASSES_ROOT\giffile\shell\Paint]

[HKEY_CLASSES_ROOT\giffile\shell\Paint\command]
@="\"%SystemRoot%\\System32\\mspaint.exe\" \"%1\""

[HKEY_CLASSES_ROOT\giffile\shell\printto]

[HKEY_CLASSES_ROOT\giffile\shell\printto\command]
@="rundll32.exe C:\\WINDOWS\\system32\\shimgvw.dll,ImageView_PrintTo /pt
\"%1\" \"%2\" \"%3\" \"%4\""


2. Ok, good to know, but that's not the problem.
1. A .gif file should be accessible. Check the files association for the
.gif extension under the "Files Types" tab of "Folder Options" found in
"Control Panel".

2. Yes, there's a set of filenames that are reserved in Windows:

"Do not use the following reserved device names for the name of a file:
CON,
PRN, AUX, NUL, COM1, COM2, COM3, COM4, COM5, COM6, COM7, COM8, COM9, LPT1,
LPT2, LPT3, LPT4, LPT5, LPT6, LPT7, LPT8, and LPT9. Also avoid these names
followed by an extension, for example, NUL.tx7.

Windows NT: CLOCK$ is also a reserved device name."


[Naming a File - MSDN]
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/fs/naming_a_file.asp
 
G

Ground Cover

Try changing the file association. Have it GIF files associate open in
something else - another program than the one it currently defaults to. The
current association may have a "hold" on the extension. Please let me know
if this works.

Thanks
 
P

Patrick

I tried all three. Paint crashes saying access denied, Photoed skips the
file it can't open and Gif Animator says the selected file is unreadable.
They do, however, open from inside the program, so I know it's not the
file(s).

Also, Textpad puts in its own menu item through a shell extension and I
tried that just to see what happened... it reads it.
 
P

Plato

=?Utf-8?B?VGFuZXRo?= said:
Ever heard of windows denying access to filenames? Not specific types, not
dangerous files, not secured files, but filenames.

Any file on my computer that ends in .gif gives the message "Access is
denied." when I try to open it. If I rename the file to .jpg or something
else, it opens fine (though that's not a good thing to do, obviously). Any
other image file opens fine, and if I rename one of them to .gif and try to
open it, I get "Access is denied."
And it's not just image files. Any file that opens with no problem, when
renamed to .gif and opened, results in "Access is denied."

How do I fix this?

Fix your file association problem
 
P

Patrick

If it was that simple, I would have done it already. It is not file
association. Their paramaters are identical to jpg and bmp, and those work
fine.
 
R

Ramesh, MS-MVP

Patrick,

I could spot atleast one problem in your GIF file association setting.

- - -
[HKEY_CLASSES_ROOT\giffile\shell\Paint\command]
@="\"%SystemRoot%\\System32\\mspaint.exe\" \"%1\""
- - -

The (default) value is of type REG_SZ, but it's data consists of environment
variables, which actually should be of type REG_EXPAND_SZ.

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


If it was that simple, I would have done it already. It is not file
association. Their paramaters are identical to jpg and bmp, and those work
fine.
 
P

Patrick

Thanks, that was it. I changed that to full path and it fixed the whole
thing. I wander how it got like that, I haven't changed it in months.
 
R

Ramesh, MS-MVP

You're welcome!

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


Thanks, that was it. I changed that to full path and it fixed the whole
thing. I wander how it got like that, I haven't changed it in months.
 

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