9

It used to be that when I renamed a class file (maybe also others) in VS2012, it prompted me to renamed everything, then did a nice refactor after renaming the class to the new file name. It suddenly stopped doing that. Does anyone know why it stopped, without me changing config or anything, or under what circumstances it doesn't work?

ProfK
  • 44,292
  • 106
  • 358
  • 713
  • Possible duplicate of [Visual Studio "rename" refactoring](http://stackoverflow.com/questions/15065772/visual-studio-rename-refactoring) – JumpingJezza Mar 04 '16 at 02:07
  • I no longer receive this prompt, anyone know where the setting is so I can get this prompt once again? And the answer is not in the thread from the comment above – DanO Nov 08 '16 at 12:09
  • 3
    I made sure the checkbox "Prompt for symbolic renaming when renaming files" was checked under the Menu: Tools / Options expand Projects and Solutions . – DanO Nov 08 '16 at 12:21

1 Answers1

-1

Try changing class name, not file name. As 1 file can holds multiple classes. (Don't know if this is true for VS, but it works like that in Java's Eclipse & IntelliJ.)

FazoM
  • 3,929
  • 5
  • 38
  • 58
  • If I change the class name in its case only, I don't get the prompt to rename the file to match the class, and I have to do it as another, separate operation. I'm working with 245 classes. – ProfK Nov 09 '13 at 12:02