Author Topic: Win7 (x64) batch file associations  (Read 2903 times)

srouleau

  • Community Member
  • Posts: 67
  • Hero Points: 4
Win7 (x64) batch file associations
« on: September 08, 2010, 12:33:41 pm »
Just upgraded from WinXP to Win7. Early adopter, I know...

Also upgraded from VS2009 to 2010 at the same time. Good times!

I set file associations in VS on bat and cmd, and lo and behold this changed the default action, so that now double-clicking on .bat or .cmd opens up VS. Even more fun, typing the name of a .bat or .cmd in a command prompt will also open VS. Good times.

I was able to revert this by mucking around in the registry, but let's just say this wasn't the behavior I was expeting.  :)

Steph

ScottW, VP of Dev

  • Senior Community Member
  • Posts: 1471
  • Hero Points: 64
Re: Win7 (x64) batch file associations
« Reply #1 on: September 08, 2010, 05:42:14 pm »
Sorry if I'm being thick, but what behavior were you expecting? The double-click behavior sounds right. I'm not sure about the typing the name of a .bat or .cmd file though.

This should have had the same result as if you went to Control Panel > Default Programs > Set Associations and associated those extensions with SlickEdit.

srouleau

  • Community Member
  • Posts: 67
  • Hero Points: 4
Re: Win7 (x64) batch file associations
« Reply #2 on: September 09, 2010, 02:46:29 pm »
You're not being thick, I was being a bit of a dimwit it seems. You're right, by default doing the file association will result in double-clicking launch that app.

However I just tried it again on an XP system where I thought I had Slick Edit already setup with this file association. Turns out it wasn't, but it's interesting.

BEFORE:

Double-Click: launches the command interpreter.
Right-Click:
   Open
   Edit. 

Edit launches notepad  (augh!), Open does the double-click action.

AFTER setting file association through VS (2009 in this case):

Double-Click: launches Slick Edit
Right-Click:
   Open

No Edit menu entry. I guess I was hoping that it would've just changed the Edit verb; I suppose for .bat/.cmd I should edit it through Windows rather than through the VS config.

Steph