PowerCommands for Visual Studio 2008

I found a handy set of tools for VS 2008 IDE.   One of my favorites is the "Collapse Projects"!  Why this isn’t already in the IDE, I have no idea.  But here is the link and a list of commands:

 

http://code.msdn.microsoft.com/PowerCommands

 

 

Below is a list of the included in PowerCommands for Visual Studio 2008 version 1.1. Refer to the Readme document for additional command details and screenshots.

Enable/Disable PowerCommands in Options dialog
This feature allows you to select which commands to enable in the Visual Studio IDE. Point to the Tools menu, then click Options. Expand the PowerCommands options, then click Commands. Check the commands you would like to enable.
Note: All power commands are initially defaulted Enabled.

Format document on save / Remove and Sort Usings on save
The Format document on save option formats the tabs, spaces, and so on of the document being saved. It is equivalent to pointing to the Edit menu, clicking Advanced, and then clicking Format Document. The Remove and sort usings option removes unused using statements and sorts the remaining using statements in the document being saved.
Note: The Remove and sort usings option is only available for C# documents.
Note: Format document on save and Remove and sort usings both are initially defaulted OFF.

Clear All Panes
This command clears all output panes. It can be executed from the button on the toolbar of the Output window.

Copy Path
This command copies the full path of the currently selected item to the clipboard. It can be executed by right-clicking one of these nodes in the Solution Explorer:
The solution node; A project node; Any project item node; Any folder.

Email CodeSnippet
To email the lines of text you select in the code editor, right-click anywhere in the editor and then click Email CodeSnippet.

Insert Guid Attribute
This command adds a Guid attribute to a selected class. From the code editor, right-click anywhere within the class definition, then click Insert Guid Attribute.

Show All Files
This command shows the hidden files in all projects displayed in the Solution Explorer when the solution node is selected. It enhances the Show All Files button, which normally shows only the hidden files in the selected project node.

Undo Close
This command reopens a closed document , returning the cursor to its last position. To reopen the most recently closed document, point to the Edit menu, then click Undo Close. Alternately, you can use the CtrlShiftZ shortcut.
To reopen any other recently closed document, point to the View menu, click Other Windows, and then click Undo Close Window. The Undo Close window appears, typically next to the Output window. Double-click any document in the list to reopen it.

Collapse Projects
This command collapses a project or projects in the Solution Explorer starting from the root selected node. Collapsing a project can increase the readability of the solution. This command can be executed from three different places: solution, solution folders and project nodes respectively.

Copy Class
This command copies a selected class entire content to the clipboard, renaming the class. This command is normally followed by a Paste Class command, which renames the class to avoid a compilation error. It can be executed from a single project item or a project item with dependent sub items.

Paste Class
This command pastes a class entire content from the clipboard, renaming the class to avoid a compilation error. This command is normally preceded by a Copy Class command. It can be executed from a project or folder node.

Copy References
This command copies a reference or set of references to the clipboard. It can be executed from the references node, a single reference node or set of reference nodes.

Paste References
This command pastes a reference or set of references from the clipboard. It can be executed from different places depending on the type of project. For CSharp projects it can be executed from the references node. For Visual Basic and Website projects it can be executed from the project node.

Copy As Project Reference
This command copies a project as a project reference to the clipboard. It can be executed from a project node.

Edit Project File
This command opens the MSBuild project file for a selected project inside Visual Studio. It combines the existing Unload Project and Edit Project commands.

Open Containing Folder
This command opens a Windows Explorer window pointing to the physical path of a selected item. It can be executed from a project item node

Open Command Prompt
This command opens a Visual Studio command prompt pointing to the physical path of a selected item. It can be executed from four different places: solution, project, folder and project item nodes respectively.

Unload Projects
This command unloads all projects in a solution. This can be useful in MSBuild scenarios when multiple projects are being edited. This command can be executed from the solution node.

Reload Projects
This command reloads all unloaded projects in a solution. It can be executed from the solution node.

Remove and Sort Usings
This command removes and sort using statements for all classes given a project. It is useful, for example, in removing or organizing the using statements generated by a wizard. This command can be executed from a solution node or a single project node.

Extract Constant
This command creates a constant definition statement for a selected text. Extracting a constant effectively names a literal value, which can improve readability. This command can be executed from the code editor by right-clicking selected text.

Clear Recent File List
This command clears the Visual Studio recent file list. The Clear Recent File List command brings up a Clear File dialog which allows any or all recent files to be selected.

Clear Recent Project List
This command clears the Visual Studio recent project list. The Clear Recent Project List command brings up a Clear File dialog which allows any or all recent projects to be selected.

Transform Templates
This command executes a custom tool with associated text templates items. It can be executed from a DSL project node or a DSL folder node.

Close All
This command closes all documents. It can be executed from a document tab.

 

 

Great stuff!  Happy Coding!

 

 

Posted in Development | Leave a comment

Visual Studio SP1 IDE Crashes

I have not been immune to the tortuous IDE crashes in Visual Studio SP1.  Thankfully, enough screams have been raised that a fix is available.  Somehow I missed this back in May.  Hopefully, the rest of you won’t miss it even longer than I have.  You can find the information about it here along with the associated hotfix.  Just make sure that you are suffering from the problem indicated before installing.

Happy Coding!

 

Posted in Development | Leave a comment

Quirks working with Workflow Designer

When working with Windows Workflow Foundation projects, it’s easy to get into the routine of working with your activities in the designer.  This is all great and wonderful until the complexity increases.  For example, if you have activities that are sequential workflow units themselves, this can lead to some real ‘Workflow Designer Heartburn’. One example, I have a large application with many workflow activities that are sequential workflow units themselves.  If I create yet another activity that is a ‘Code’ activity (as opposed to code behind), then the current VS 2008 designer will sometimes just flat refuse to let me drop other sequential workflow code activities into it.  To get around this, you can create a code behind activity.  For some reason, the designer seems to have less problems with this.  I’m just hoping that some of these designer issues are addressed in the forthcoming VS2010.
 
Happy Coding
 
Posted in Development | Leave a comment

Great things coming to Windows Workflow 4.0!!!

What’s new in .NET Framework 4.0

 

·         Next versions of Windows Communication Foundation (WCF) and Windows Workflow Foundation (WF) will provide better support for Web 2.0 technologies like REST, POX, ATOM.

·         Performance and Scalability of WCF and WF are expected to increase by minimum 10X.

·         New workflow models.

·         Seamless integration between WCF and WF including a new Visual Designer.

·         Parallel Programming framework using PLINQ, Task Parallel Library and Coordination Data Structures to better utilize power of multi-processor and multi-core machines.

·         Build declarative applications with WF, WCF and WPF using XAML. So, XAML is no more only for WPF and WF.

·         WCF enhancements :

o    RESTful enhancements

§  Simplifying the building of REST Singleton & Collection Services, ATOM Feed and Publishing Protocol Services, and HTTP Plain XML Services using WCF

§  WCF REST Starter Kit to be released on Codeplex to get early feedback

o    Messaging enhancements

§  Transports – UDP, MQ, Local in-process

§  Protocols – SOAP over UDP, WS-Discovery, WS-BusinessActivity, WS-I BP 1.2

§  Duplex durable messaging

o    Correlation enhancements

§  Content and context driven, One-way support

o    Declarative Workflow Services

§  Seamless integration between WF and WCF and unified XAML model

§  Build entire application in XAML, from presentation to data to services to workflow

·         WF enhancements :

o    Significant improvements in performance and scalability

§  Ten-fold improvement in performance

o    New workflow flow-control models and pre-built activities

§  Flowcharts, rules

§  Expanded built-in activities – PowerShell, database, messaging, etc.

o    Enhancements in workflow modeling

§  Persistence control, transaction flow, compensation support, data binding and scoping

§  Rules composable and seamlessly integrated with workflow engine

o    Updated visual designer

§  Easier to use by end-users

§  Easier to rehost by ISVs

§  Ability to debug XAML

 

 

Posted in Development | Leave a comment

Microsoft Web Platform & Web Application Installers!

Now here’s something to check out!  Microsoft has released v1.0 of it’s Microsoft Web Platform Installer to make it easy to get set up to start doing web development.  It installs IIS, VS Web Developer 2008 Express, SQL Server 2008 Express and the .Net Framework.  And when they went from beta to v1.0, they added the new ASP.NET MVC, VS Tools for Silverlight and more!  Way to go guys!
 
The Microsoft Web Application Installer is (unfortunatly) still beta but help you get up and doing web development if you need tools other than what comes with the Platform AI.  You can install things like Graffiti, DotNetNuke, WordPress, Drupal, OSCommerce and more!  It checks your machine for the necessary pre-requesites and will pull the apps from their source.  Then it walks you through the configuration process and installs them on your computer.
 
All in all, these two are an incredible benefit for anyone wanting to get up and running quickly.  Way to go guys!!!
 
Happy Coding!
Posted in Development | Leave a comment

Office developer with VS 2010

We have some exciting and dramatic improvements coming for developing Office based solutions.  As we all know, developing Office based solutions has been a bit confusing not to mention problematic (can we all say COM+ and PIA???).  Well, I’m very excited to say that it looks like we have some significant relief coming with VS2010.

·         Publishing to SharePoint – Up to now, if you wanted to put an Office based solution on to SharePoint, you had to manually upload the document and maintain locations between the document and the assemblies.  VS2010 is slated to provide a ‘one-click’ mechanism for publishing your solution.  The assemblies will be stored on the SharePoint server itself!!! (What a concept, huh?)

·         Customized and enhanced deployment packages – Up to now, if you created a solution that used both Excel and Word, you had to create multiple deployment packages and customization was still a challenge at times.  With VS2010 you will be able to deploy multiple solutions in a single package.  You will also have more deployment package customization features!

·         PIA-less Interoperability – OK, I saved the best for last!  If you develop these types of solutions, you know how much fun (sarcasm intended) you had with PIA (making sure it was deployed, interoperability issues, etc).  Now, with VS2010 and CLR v4.0, you can use a new feature that will embed the IOP interfaces directly into your application assembly!!!!  We can get rid of the deployment headaches as well as the 6.3MB PIA redistributable!

 There are loads of new features coming in VS2010 that I’ll get into later, but I just felt for all of us who develop Office based solutions should know that we have great things coming!!

 Happy Coding!

Posted in Development | Leave a comment

Great presentation style on Identity 2.0

This is a great presentation style not to mention great information on Identity 2.0 from Steve Clayton.  It’s definitely worth your time to watch:
 
Posted in Computers and Internet | Leave a comment

Silverlight Toolkit November 2008 on CodePlex

I’ve kept my trap shut about this for a while (it was posted October 28th) because I wanted to see exactly what it was about and also to see if my opinions were a bit off from everyone else’s.  It’s been out for a couple of weeks now so I feel I can comment without going into too much detail.

I was really REALLY looking forward to seeing what the SL bunch posted for this Toolkit.  I was hoping for many gadgets that all developers need to build real LOB Web Apps quickly.  I just have to admit that I was a bit dissappointed.

Don’t get me wrong, the toolkit that they published was more stable and a bit more polished that I had expected but yet, it contained only a fraction of what I was hoping for.

The build contains a TreeView (nicely done with some unexpected features), a DockPanel (a little confusing if you want dynamic docking but good to have), a WrapPanel (I’m still trying to decide why effort went into this one), a ViewBox (this will be great for resizing but only if you have images, doh!), a label (WTH??? Just tell me why?) and a few others I won’t even go into.

Decent quality code, but several seem like a waste of time and effort.  I still don’t understand why there wasn’t a HUGE effort to create a great GRID control!?!?!?!?!?  The ‘Grid’ (if you even want to call it that) in SL2 is just an HTML table with no features.  A grid is the one if the first things I grab out of the toolbox when I’m creating LOB apps.

So, I’m at a quandry whether to recommend it or not.  It’s definitely worth looking at the code but as for relying on it for one of your ‘at-your-fingertips-tools’, I dunno.  Email me what you think.

Happy Coding.

Posted in Silverlight | Leave a comment

Silverlight 2.0 RTW

Sorry to be quite so long.  We’re releasing and it’s been quite exciting around here.  However, I just HAD to post this about the Silverilght 2.0 RTW release that came out today.  If you’ve been using SL2 Beta 2 in your sites, you’ll be very interested in this.
 
If you have any users at all that were running SL Beta 2, you’ve already found out the browsers running the new RTW bits are having issues with your site.  You will need to update your site’s type tag from type="application/x-silverlight-2-b2" to type="application/x-silverlight-2".   Moroney has a more detailed explaination and it’s a quick read.
 
Also, you will have to recompile your SL controls with VS2008 SP1
 
I’m sure there is a way to support both, but hey, a Beta is a Beta.  It wasn’t intended to be permanent.
 
Now, let’s see what you can do with this fantastic update!!!!
 
Happy Coding!
 
 
Posted in Silverlight | Leave a comment

Another note about removing VS2008 Beta

Just one more note about removing/recovering from VS2008 Beta.  if you had installed the VSTS Explorer while you had the beta installed, you may have to uninstall everything to do with VS and rebooting before you can recover.  One of the indicators that you have reached this confused state is that you will try to debug an application (this is especially relevent to 64-bit systems) and you get an error indicating that the debug components are not registered.  Don’t panic (and don’t wipe your system), just be patient and work to get the VS beta completely off of your system.  If you can’t uninstall, you may have to go to MSDN and use the VS2008 SP removal tool to get the SP off first.  If you still can’t get an uninstall  clean, you may have to do either a install or repair THEN try to uninstal before you can get to a clean starting point.
 
Then be sure to reboot before installing the non-Beta VS.  Patience & Persistence is the key asset in this situation.
 
Happy Coding.
Posted in Development | Leave a comment