Effective Use of Visual Studio 2005 – Named Commands

Command Window: Ctrl+Alt+A

Named commands are used to access VS features from Command Window. Visual Studio 2005 provides full intellisense support in the command window. I experienced that using named commands is much faster than accessing these features with mouse.

Named commands allow you to access and use menu commands in the command window. To use named commands, simply type the name of menu. Press ‘.’ and VS will provide intellisense. Type the name of the menu option or select it from intellisense.

Example:

To access Find Results 1 window you have to

1. Click on the ‘View’ menu and then
2. Click on the ‘Find Results’ and
3. Finally choose ‘Find Results 1’.

Now if you want to use named commands,
1. Press Ctrl+Alt+A to activate command window.
2. Type View.findresults1. You don’t need to type full text. Intellisense provides yoy write text. Just press enter.

Some Examples of Named Copmmands:

  • Window.NewWindow: Open a new window on your code.
  • Tools.Options: Bring up Options dialog box.
  • Edit.ViewWhiteSpace: (Ctrl+R, Ctrl+W) Replace white spaces with a dot.
  • Convert tab to spaces: Ctrl+K, Ctrl+D
  • Window.ActivateDocumentWindow: Switch to document window.
  • Window.AutoHide: Hide command window. (Use Ctrl+Alt+A to show command window)
  • Window.AutoHideAll: Hide all windows except document windows. It will hide even pinned-up windows too.
  • Window.ShowEzMDIFileList: Show Easy MDI File List.
  • Window.Split: Split code window into two. Both windows show same files but you can scroll them independently. Issue same command to close splitting.
  • Window.Windows: Open ‘Windows’  window. More Info
  • Edit.ClearAll: Clear Command Window.

Named Command and Keyboard Shortcuts

Usually VS features can be accessed in two ways: using keyboard shortcusts or  using named commands. But using named commands is easier than using keyboard shortcuts:

  1. You need to learn keyboard shortcuts. But named commands are not required to learn, as they are based of the menu navigation which is most commanlyt used.
  2. Keyboard shortcuts are customizable. You (or anybody else) can change them. If you are working on some other machine, you may not have same keyboard shortcuts.
  3. There is no help (intellisense) provided for keyboard shortcuts.

Images:

1. Easy MDI File List

EzMdiFileList

2. Split code window
Untitled

Effective Use Of Visual Studio 2005 – Handling Open Documents

Visual Studio 2005 provides some excellent document management capabilities. Most of the we are not aware of these features. One of the feature is open document tab groups. Unlike VS 2003, it shows only as much tabs as fits in the window width. There is no scrolling. Instead, VS 2005 provides dropdown menu to select from all open documents. Inseated of selecting open documents, you can also do some other functions.
I am planning to write a series on useful-but-less-known features of VS 2005. This is second post in the series. (read first post)

In continuation to my previous post on managing open documents, here are some more tricks.

Right click on the open document tab group. A context menu will appear with following options:
  1. Save default.aspx.vb
  2. Close
  3. Close all but this
  4. Copy full path
  5. Open containing folder
  6. New horizontal tab group
  7. New vertical tab group

Save default.aspx.vb

Allows you to save currently selected document. Currently selected document is the one which is open in the window.
Close
Close currently selected document.
Close all but this
Close all open documents except the currently selected document.
Copy full path
Copy full path of the currently selected document to the clipboard.
Open containing folder
Open the folder that contains the currently selected document. The folder is opened in the windows explorer.

New horizontal tab group
Open another document window. The two windows are tiled horizontally. Both window will have document tab group. This is useful when you want to open on two group of documents simultaneously.

New vertical tab group

Same as above option. But this makes the windows tiles vertically instead of horizontally.

Effective Use of Visual Studio 2005 – Closing Selected Window

To close open documents selectively:
1. Go to Window -> Windows.

2. This will show list of all open windows (not just those which you see on the tabs).

3. Select the windows you want to close. Use shift (or ctrl) key for multiple selection. You can also use ctrl+A to select all windows.

4. Click “Close window(s)” button to close selected windows.

I experienced that the speed of loading a project into visual studio is directly proportional to the number of open documents. Generally, we open the document as we need it. And then we don’t close it. Visual studio 2005 displays only a few number of documents on the tabs. Rest remains open but are hidden. You can click on the down arrow near the ‘X’ button of the document window to select the open document. To keep you project loading fast, always keep minimum number of open documents.

Microsoft Popfly – Share Visual Studio Projects On The Web

 

Popfly allows you to build gadgets and web pages. It also allows you to share your creation. Popfly provides online visual tools for creating Web pages and gadgets. You can host, share, rate, comments and even remix creations from other popfly users.

Here are some things you can do with Popfly:

Add some fun to your Facebook page, web site, or Windows Live Spaces page.

You can easily spice up your Web site or blog with Popfly by adding customized games like Whack-a-mole or asteroids with pictures of your friends and family or create custom quizzes or polls that you can easily embed on your Web site.

Build a Home Page:

You can build a custom home page, say for your school’s sports team and choose from over 150 different themes, 10 styles, and 30 unique color themes for a unique visual design. You can then easily add things like team photos, a team schedule from an RSS feed, video from previous games, Virtual Earth maps with directions to game locations and more, all without writing code.

Mix and Re-mix Photos and Videos:

Popfly makes it easy to create and share beautiful slideshows using pictures from Flickr, Windows Live Spaces, Facebook or to embed a podcast or a video player hosting videos from Soapbox or YouTube and share it on your Facebook profile, Windows Live Spaces page, or any Web page.

Unify Your Online Personality:

Popfly enables you to customize and stitch together your online persona in one place. You can create mashups that show what you dug on Digg.com, what you are buying or selling on eBay, you Halo 3 game scores, what Facebook events you’re attending, what your friends are doing on Twitter, and much more.

Share Visual Studio Projects:
Popfly offers a powerful web programming environment to bring in new data sources, create new ways to display information, or even create and share full Visual Studio projects.

Popfly Explorer for Visual Studio and Visual Studio Express:

Popfly Explorer is a plug-in for Visual Studio that lets you:

  • Effortlessly create and host a Popfly web site
  • Access your Visual Studio solutions from anywhere
  • Share Visual Studio solutions with friends
  • Add mash-ups to your web pages

Links:

How To Purchase A Laptop

Question: How many people are required to purchase a laptop?

Answer: Five.

Question: And what is the flowchart of purchasing a laptop?

Answer: Acquire 100% resources –> Drink beer –> Have lunch –> Go to theatre –> Watch movie –> Then release 60% of resources and utilize 40% resources to buy laptop –> The process is exhausting so re-energize 40% resources with more beer.

Don’t believe me? Read the story below (it’s real):

Bob is a software professional who is working for a large MNC. Currently he is posted at client side. He has a team of six people who share good chemistry. Today one of his team mate Mr. M decided to buy a laptop. His office is very near to largest electronics market so it was decided that team will go to buy laptop in the lunch time.

Unfortunately, nobody in the team brought their car today. Usually people use company provided cabs for commute from home to office and back. So they decided to hire an auto. Bob and his mates asked many auto driver but all denied. Finally it was decided that they will take bus. After long wait bus stand, finally a bus arrived. Frustrated after waiting long time, they were onboard in fraction of seconds. Things seemed to be on the right path when they discovered that they had boarded wrong bus. After changing the bus at the next stop, they finally went to the market.

While passing through the theatre M proposed for watching the movie. Mr. V proposed for having lunch. Se it was decided that they will watch the movie after lunch and they they will buy laptop. The restaurant was unfortunately close to the beer and wine shop. It allowed carry and drink facility. Mr. D proposed for beer and Mr. G immediately approved. V and M gave silent approval. Bob doesn’t take alcohol so his vote was neutral. Since nobody opposed the idea, they decided to have beer first, and than lunch and then movie. Purchasing laptop was last in the list.

Things went well as planned. They had beer and then had lunch. After lunch every body enjoyed movie. D and G want to have more beer. But theatre management didn’t allow them to go outside while the show was running. By than, it was evening and almost dark. The office cab would leave in the one hour. So it was decided that first they will go to office and M and D will come back to buy laptop. D wanted to drink more beer. He proposed to drink one more beer and then go to office and then come back to buy laptop. Bob along with G and V opposed it. Going to office after having beer was not appropriate. So finally it was decided that M and D will purchase laptop, have more beer and than went to home. Bob, G and V will go back to the office.

What happened next is that they follow the plan. In the night Bob called M to confirm weather they had purchased the laptop or not. M had purchased it.

Who is Bob? It’s a suspense. I will revel it at the appropriate time.

Technorati Tags: , , , ,

Visual Studio 2008 and .NET 3.5 Released

Microsoft shipped Visual Studio 2008 and .NET 3.5 today. Here are some resources for VS 2008:

1. ScottGu’s weblog is the primary and authentic source of information।
२. Somasegar’s Weblog
3. Paul Andrew blogged about a downloadable poster of commonly used types and namespace in .NET 3.5 (in pdf format), which is worth checking out.
4. View ASP.NET 3.5-specific videos at Microsoft’s official asp.net website.
5. Brad Abrams wrote about Design Guidelines, Managed code and the .NET Framework 3.5 in his blog.
6. Here is a 31 minute video at Channel 9.
7. VS 2008 is not shipped with MSDN. You can Download MSDN Library for VS 2008 from here.
8. The details about VS 2008 express edition (free) are available here.

Benefit of Using Technorati Tags on your blog

 

Today, I received a mail from one of my old friend. he happened to visit my blog and was surprised to see Technorati tags there. He called me up to ask what these tags are and why I used them on my blog. In his own words,

“Yaar, your blog seems to be advertising for this web site called Technorati.com. Are you being paid for this?”

I was quite surprised to see the reaction of Technorati tags. Then  I told him what Technorati tags are and why I use them on my blog.

Later on I thought that many other people might also be thinking in the same way. So I decided to post a blog entry on this matter.

Tags are keywords or topics which you place at the bottom (or anywhere) of your blog post to catch the attention of Technorati and other search engines. Technorati is a search engine which indexes the blog which uses its tags. Technorati doesn’t pay anything to me anybody to place a Technorati tag on his blog. They even don’t pay me to write these stuff though I am advocating to use Technorati tags on your blog. (I wish they should pay me for that. Ha ha ha). Instead it helps the blog author in many ways (see below).

A common question arises – why Technorati do all this? The answer is that when you place a link of Technorati tag on your page, you increase the popularity of Technorati. When millions of blogs do the same thing, Technorati gets great page rank and a very very large number of hits on its pages. Technorati puts ads on its pages and the amount one charges to display an ad is directly proportional to number of hits on that page. So Technorati earns money indirectly. But that is not the concern of a blog author. As an author of a blog, I get many free of cost benefits by using Technorati tags.

The benefits of using Technorati Tags on your blog:

1. It gets your page recognized by Technorati and other blogosphere search engines thus increasing the chance of people finding your blog.

2. It gets your blog indexed on search engines like Google, yahoo etc. driving more inward traffic to your blog and increasing popularity and readership.

3. It increase page views per visit because readers can find more on a topic that interests them.

Technorati Tags: , , , , ,