none
How to sort/order projects in VS2008 Solution Explorer?

    Question

  • I just upgraded to VS2008 RTM and loaded/converted a VS2005 solution with several projects grouped into three subfolders. I'm really used to the folders (and projects within the folders) sorted in ascending order per project name. In VS2008 they are in random order and I can't find a way to put them back into ascending order. Any suggestions?

    Tuesday, November 27, 2007 5:49 PM

Answers

  • Thanx for your feedback. I surely also hope for a fix, it's very annoying.

     

    Yes, we also use solution folders

     

    BTW, I found a “workaround” which I posted on the other bug report:
    Pressing F2 and then enter (without changing anything) forces the SE to resort current brach.

     

    Wednesday, February 20, 2008 2:58 PM
  • Hi,

    You may track this feedback at connect: https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=312252&wa=wsignin1.0

    As a workaround, you could organize projects with different folders, and in Solution Explorer window the folders' order is ascending.

    Thanks
    Thursday, November 29, 2007 9:39 AM
  • I discovered a similar, perhaps more simple, workaround:  I added a single folder to the unordered solution and named it 'AAA' and then SE reordered all of my solution folders and projects within those folders in ascending order as it was in VS2005.

     

     

     

     

     

    Thursday, November 29, 2007 4:44 PM
  • I've found simple workaround that worked for me.

    Just turn on the "Show miscellaneous files in Solution Explorer" option (On the Tools menu, select Options. In the Options dialog box, expand the Environment node and choose Documents). Ssolution must be reopened to changes take effect.

     

    Thursday, February 07, 2008 2:12 PM
  • Some more experiments showed that the "Show miscellaneous files in Solution Explorer" option does not affect the order of projects.

     

    I've noticed, what does matter is whether a solution folder is collapsed or expanded before closing the solution.

    When collapsed, after reopening solution and clicking the + sign on the folder, the solution explorer window flickers for several moments (sorting projects, I guess), and projects in the folder are sorted alphabetically.

    If before closing the solution some folders are expanded, then after reopening the solution the projects in that folders may be not ordered.

    Monday, February 11, 2008 8:25 AM

All replies

  • Hi,

    You may track this feedback at connect: https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=312252&wa=wsignin1.0

    As a workaround, you could organize projects with different folders, and in Solution Explorer window the folders' order is ascending.

    Thanks
    Thursday, November 29, 2007 9:39 AM
  • I discovered a similar, perhaps more simple, workaround:  I added a single folder to the unordered solution and named it 'AAA' and then SE reordered all of my solution folders and projects within those folders in ascending order as it was in VS2005.

     

     

     

     

     

    Thursday, November 29, 2007 4:44 PM
  • I've found simple workaround that worked for me.

    Just turn on the "Show miscellaneous files in Solution Explorer" option (On the Tools menu, select Options. In the Options dialog box, expand the Environment node and choose Documents). Ssolution must be reopened to changes take effect.

     

    Thursday, February 07, 2008 2:12 PM
  • None of these suggestions worked for me. My folders are in the correct order, but the projects within them are not.

     

    I've already sent FeedBack to MS about it (https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=327358) but so far it is still not resolved.

     

    Any other ideas for workarounds for me to try?

    Friday, February 08, 2008 7:10 PM
  • Some more experiments showed that the "Show miscellaneous files in Solution Explorer" option does not affect the order of projects.

     

    I've noticed, what does matter is whether a solution folder is collapsed or expanded before closing the solution.

    When collapsed, after reopening solution and clicking the + sign on the folder, the solution explorer window flickers for several moments (sorting projects, I guess), and projects in the folder are sorted alphabetically.

    If before closing the solution some folders are expanded, then after reopening the solution the projects in that folders may be not ordered.

    Monday, February 11, 2008 8:25 AM
  • OMG! That's it! Thank You, Thank You, Thank You!!! You have no idea how much time I've wasted on trying to track this down!!

     

    I owe you big time!

    Monday, February 11, 2008 7:08 PM
  • Ouch! Minor little gotcha guys ... the above workaround does work until .... the next time you close the solution with any of the solution folders expanded ... then you're right back to having them out of order again. Not good ... please go to the Feedback link and let's get this issue the attention it deserves! 


    https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=327358

    Tuesday, February 12, 2008 1:49 AM
  • Just upgraded a solution from 2005 to 2008 and got same problem :-(

     

    BTW note the item mentioned in the begining of this post.

    https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=312252

     

     

    Wednesday, February 20, 2008 12:51 PM
  • Thomas, they're working on it. I submitted a Feedback Bug also (don't know if you went to the link in my last post). We continued on a bit via email, so the whole "conversation" with Microsoft isn't in the comment of my Feedback submission.

     

    The problem, as I see it, had to do with Solution Folders ... do you use those in your solution? Here's a direct quote from one of the guys I'm dealing with via email:

     

    We are looking into a fix for this issue. Apparently this was caused by another change late in the product cycle.

     

    So, at least it's been acknowledged as a bug and they have seen it happening with my solution that I sent them. Now, let's hope for a quick fix. This is quite unusable to me at the moment.

    Wednesday, February 20, 2008 2:32 PM
  • Thanx for your feedback. I surely also hope for a fix, it's very annoying.

     

    Yes, we also use solution folders

     

    BTW, I found a “workaround” which I posted on the other bug report:
    Pressing F2 and then enter (without changing anything) forces the SE to resort current brach.

     

    Wednesday, February 20, 2008 2:58 PM
  • Thomas, thank you ... of all the workarounds I've heard for this issue, this is certainly the easiest and the only one I would call acceptable. I can now say that I can live with this bug, with this is as a workaround, until a fix rolls around.

     

    I'll post this workaround in my own Feedback bug report as well.

     

    Thanks a bunch!

    Wednesday, February 20, 2008 3:36 PM
  • On the connect site it says this bug is resolved? Is it really? I am still having the same problems a year later. What gives?
    Wednesday, April 01, 2009 7:34 PM
  • I didn't see that it was resolved. Which link on the connect site did you look at? The bug that I filed was marked as "Closed(Duplicate)", but I'm not sure where the duplicate bug is. At any rate, I don't think it has been fixed, unless there's a new Service Pack that I haven't gotten, but I'm pretty sure I've got the latest, 9.0.30729.1 SP.
    ~~Bonnie Berent [C# MVP]
    Sunday, April 12, 2009 1:10 AM
  • https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=312252

    ... is closed as not-reproducible. WTF?

    The other issue is a duplicate of 312252.
    Wednesday, June 17, 2009 8:59 AM
  • I don't know why this keeps coming up and they keep closing it without fixing it. It's an obvious bug, they *can* and *have* reproduced it, but still don't fix it. I don't get it.  =0(

    Anyway, the workaround that Thomas posted above is acceptable ... just would be nice if someone would fix it.


    ~~Bonnie Berent [C# MVP]
    Thursday, June 18, 2009 4:29 AM
  • Hi,

    Seeing as they closed the feedback as "non reproducable" I've submitted a new feedback request with some very detailed reproduction steps.

    Could everyone please vote for it and mark it as validated so we can get this sillly bug sorted? :-)

    https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=468874

    Thanks,

    DoctaJonez
    The customer isn't always right, but the customer is always the customer.
    Monday, June 22, 2009 11:37 AM
  • They've replied and said they're passing it onto the product team.  Fingers crossed that they'll sort it!

    http://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=468874

    "Thanks for your feedback. We are routing this bug to the product unit who works on that specific feature area. The team will review this issue and make a decision on whether they will fix it or not for the next release.

    Thank you,
    Visual Studio Product Team"


    The customer isn't always right, but the customer is always the customer.
    Tuesday, June 23, 2009 8:37 AM
  • I put in my 2 cents on the Feedback site.
    ~~Bonnie Berent [C# MVP]
    Saturday, June 27, 2009 8:42 PM
  • The 'F2' workaround doesn't seem to work for me: there's a screen flicker like it's done something, but the sort order is still not right (ie not sorted alphabetically in any way I can fathom)

    [edit: need to select Project not solution folder. See below]
    • Edited by piers7 Thursday, August 27, 2009 1:03 AM clarification
    Wednesday, August 26, 2009 12:54 AM
  • And you are positioned on a Project in the Solution Explorer when you press F2?
    ~~Bonnie Berent [C# MVP]
    Wednesday, August 26, 2009 3:32 AM
  • Ah. On a Project. I was thinking you had to do this on the Solution Folder. Yes it works when I do that.

    ...until I shut the solution, whereapon it's back to being disordered.

    I tried http://solutionsorter.codeplex.com/ but since my solution folders are nested it ate my solution :-(

    Thursday, August 27, 2009 1:02 AM
  • So as best I can see there are 4 seperate connect issues for this:

    https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=312252
    https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=327358
    https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=366825
    https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=468874

    What a mess! You would think Connect would make cross-referencing these a bit easier (I love the way they get marked as 'duplicate' but you can't see what the duplicate is)
    Thursday, August 27, 2009 1:15 AM
  • Yeah, the only way to keep it sorted after you close and re-open, is to make sure that every solution folder is collapsed before you close the Solution. Only then it will re-open in the proper sort order.

    I went to all those that you posted to add my 2 cents again (one of the them was submitted by me a year and a half ago).


    ~~Bonnie Berent [C# MVP]
    • Proposed as answer by JohnnyDatabase Wednesday, November 03, 2010 3:36 PM
    Thursday, August 27, 2009 4:17 AM
  • This issue is a definite problem especially for large solutions.  I managed to implement a form of sorting in solution explorer by prefixing the solutions files with a number but the number depends on how many documents are in the solution. 

     

    For example if you have 1 to 100 documents, put the prefixes as follows:

     

    001.Report 1 -

    002.Report 2 –

    003.Report 3 -  

     

    Using this method they will sort and will allow you checklist off as completed them by number and in an order by you.  Once to add the prefixes, close the project and reopen.

     

    John McGinty

    SQL Consultant

    Wednesday, November 03, 2010 3:44 PM
  • Possible (Ugly) workaround: After I got my projects the way I wanted it, I just went into the project file (i.e., .csproj)  and re-ordered the folders/files. A tool could be written to do this automatically for you. However, once resolved by MSFT the tool would be dprecated.
    Thursday, March 10, 2011 1:54 PM
  • Didn't you read the much easier workarounds listed above?

    1. Pressing F2 and then enter (without changing anything) forces the SolutionExplorer to resort current project.
    2. The only way to keep it sorted after you close and re-open, is to make sure that every solution folder is collapsed before you close the Solution. Only then it will re-open in the proper sort order

    To be honest, I don't know if this has been fixed or not (maybe a Service Pack?) ... I'm not using VS2008 anymore and I don't remember if it was still having this problem at the time I stopped using it.


    ~~Bonnie Berent [C# MVP]

    geek-goddess-bonnie.blogspot.com
    Saturday, March 19, 2011 8:51 PM