Accessing file extensions

  • Thread starter Thread starter David P
  • Start date Start date
D

David P

Hi All,
I have a workbook containing a dozen or so macro's that i
need to distribute to around 220 people.
The macro's run OK, only if people have the "Hide file
extensions for know file types" dis-abled.
Is there any coding, that i can put into, say a WorkBook
Open event, that can change this setting on each machine?
(I know i could just tell people to turn it off, but many
either can't(due to other macros), won't, or have no idea
what i'd be talking about.)
I've had a look at FileSystemObject, but i dont think that
change this option.

Any coding assistance would be greatly appreciated.

Thanks
 
David,

I'm assuming that your problems occur when switching "windows"
between workbooks or opening workbooks from within workbooks??

To your original question.......what you want to do can probably be
done with an API call or changing a registry setting, but it's never
a good idea to mess with peoples preferences on their PC's.

Better would be to go back through your coding and insure that
you have included the ".xls" extension whenever you're referencing
a workbook or a window.

I forget which way it works, but "Windows("myFile").Activate
will work sometimes, depending on that "Hide File Extensions"
setting.
Windows("myfile.xls").Activate will always work, regardless of that
setting.

John
 
Back
Top