Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.
29285 Discussions

Editing VS2008 solution and project files

Les_Neilson
Valued Contributor II
518 Views
Has anyone experienced problems with the IDE crashing after editing project (or solution files) outside ofthe IDE?

After editing a project file with, for example, Notepad (or XMLNotepad), when I restart the IDE I get a dialog box informing me that an error has occured and after a few seconds the IDE dies. I then have to re-get the project file from our SourceSafe because all further edits give the same problem, even trying to undo the first edit that I did.

I have sometimes needed to make the samechanges to multiple (or every)projects and in the past have used(Perl) scripts to read/change/save them, but now it looks like I won't be able to do that any more, and the thought of having to go through every project one at a time using VS ...- gives me RSI just thinking about it :-(

Les
0 Kudos
4 Replies
Jugoslav_Dujic
Valued Contributor II
518 Views
Quoting - Les Neilson
Has anyone experienced problems with the IDE crashing after editing project (or solution files) outside ofthe IDE?

After editing a project file with, for example, Notepad (or XMLNotepad), when I restart the IDE I get a dialog box informing me that an error has occured and after a few seconds the IDE dies. I then have to re-get the project file from our SourceSafe because all further edits give the same problem, even trying to undo the first edit that I did.

I have sometimes needed to make the samechanges to multiple (or every)projects and in the past have used(Perl) scripts to read/change/save them, but now it looks like I won't be able to do that any more, and the thought of having to go through every project one at a time using VS ...- gives me RSI just thinking about it :-(

You can (well, are supposed to) do it -- how could the VS tell the difference between manually and automatically updated .vxproj file? Is that VS2008? (Maybe they added some smartass logic against "file corruption", nothing would surprise me with Microsoft).

...unless, of course, you do it improperly. The IDE does tend to crash in such situations though, without real trace why.
0 Kudos
Steven_L_Intel1
Employee
518 Views
I have not seen this behavior, and I have edited project files from time to time. (Solution files too.) Perhaps the file being in a code management system is relevant here.
0 Kudos
Brian_Francis
Beginner
518 Views

Hi Les,

As you probably know, the official word is to never, ever, modify .sln and .*proj files by hand. But you, me and anybody else trying to make a living using these tools ends up having to edit them to ensure consistency and save time. My recommendations:

  1. Always remove old *.ncp and *.suo generated files before loading an edited solution.
  2. Try the edit first using the ToolsOptions facility, and then make sure your manual edits preserve the exact same lettercase, layout and ordering.
  3. Reference global *.vsprops files (we have separate ones for 32 and 64 bit builds) in all C++ projects so you can easily make changes that affect all code. It's a shame that we can't use property files with Fortran projects.

I've got no hard proof that #1 and #2 make a difference, other than we don't get crashes.

Hope this helps,

Brian.

0 Kudos
Al_Worth
Beginner
518 Views
Quoting - Les Neilson
Has anyone experienced problems with the IDE crashing after editing project (or solution files) outside ofthe IDE?

After editing a project file with, for example, Notepad (or XMLNotepad), when I restart the IDE I get a dialog box informing me that an error has occured and after a few seconds the IDE dies. I then have to re-get the project file from our SourceSafe because all further edits give the same problem, even trying to undo the first edit that I did.

I have sometimes needed to make the samechanges to multiple (or every)projects and in the past have used(Perl) scripts to read/change/save them, but now it looks like I won't be able to do that any more, and the thought of having to go through every project one at a time using VS ...- gives me RSI just thinking about it :-(

Les

Have you looked into the programming capabilities of VS itself? Maybe your perl scripts cold be adapted. Please don't take this as a hard suggestion, since my knowledge of VS's programming capabilities is limited to skimming a couple of chapters in some books that made it sound like you could do anything.
0 Kudos
Reply