Jump to content

Bizarre reserved file name bug in Vista


CLASYS

Recommended Posts

Been here before, but not recently.

I develop a freeware package that has to run identically in XP and up, and I was adding a small feature while testing on a Vista64 system all the way up, but the bug presents on a clean install of Vista 64 SP2.  I have a work-around but I am stymed I have to do so.  I have to check this out in all the other supported systems, not sure if Win 7 is affected, but please help me out!

I have a shortcut to a BATCH file meant to be stored with similar ones in an open window as a control center for a bunch of related activities.  The idea is to have a shortcut on the desktop and users click on that to open this command-center window.

Most of the icons/shortcuts in that window point to one of many .BAT files in another directory, etc.  I happened to add another one and the icon winds up with the UAC elevation overlay on it.  Worse still, making changes to the icon particulars can lead to the UAC actually being required!

Here is the ONE change that makes it go away:

If I change the name of the .BAT file and a corresponding change in the shortcut info the bug totally goes away!  There seems to be a reserved keyword problem that you have to avoid the word SETUP in the file name.

In particular

If the name of the batch file is

Setup Log File.BAT  then the problem happens.

However, if I change the fille name to

Set Log File.BAT

Then the entire problem goes away.  I have isolated it down to merely what I am posting here, totally reproducible:

The problem requires that you change to a different icon, any change will do, but predictably change the icon and the problem pops out!

[The package has about two-dozen icons already, all with renamed labels on them to make sense to users, but the added frill is the only one that the BATCH FILE name pointed to starts with SETUP, and I happen to have a bunch of coherent icons, etc.]

Not sure of other variations, but why can't the name of your own BATCH file not start with S-e-t-u-p?

Any ideas.  [The renamed shortcut still says Setup Log File so it cosmetically is fine, but I've never heard of seemingly ordinary reserved filenames in Windows!

Any help?  The BATCH does some mundane things to implement a new frill feature, and that always works, just this surreal-looking problem also shows up.

Thanks in advance if anyone has ever encountered something like this.

cjl

Edited by CLASYS
I can't type
Link to comment
Share on other sites


Look on this page, under "Installer Detection Technology" (there is no contents/targets for this page so use the search)

https://technet.microsoft.com/en-us/library/cc709628(v=ws.10).aspx

For any applications you write that should not be prompting for elevation, then you should create a Manifest for your program with such instructions.

Link to comment
Share on other sites

Two things (not necessarily useful).

Batch files on non DOS based  Windows (aka any NT version) should have the .cmd extension (and not the .bat one).

Having a long file name with spaces in it starting with "Setup" most probably results in some "non-obvious place" as "Setup~1", possibly also influenced by the hiding of the extensions of the files, this and some other "remains" from previous versions of windows may actually be part of the problem.

Questions:

Does Setup_Log_File.cmd give the same issue?

Does Setup Log Something.cmd? (i.e. are you sure that the issue is the keyword "Setup" and not the keyword "File"?)

jaclaz


 


 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...