Did you know… You can create folders to organize your objects and methods within the Class View? – #347

Happy Halloween! Here’s a picture of me and Beth Massi (i’ll let you guess which is which) at her annual Halloween party. An unsuspecting Agent Smith showed up, but he didn’t know martial arts, which was anti-climatic consider this Trinity does.

Sara Ford as Trinity, and Beth Massi as a red Devil

One difference between the Class View and the Object Browser is the way to create “custom component sets” in Object Browser speak. In the Class View, you can quickly click on the folder icon to create a folder to store both objects and methods.

Class View New Folder

now you can drag both objects into the folder, as shown below

Object shown in the New Folder 1

but you can also drag individual methods (i discovered this one by accident to see what would happen).

individual method in New Folder1

And to state the obvious, since that’s what i do, you can double click a method to jump straight to it in code (if it is a part of your solution; otherwise, if a part of the framework, it’ll jump into the object browser).

method in code

Technorati Tags: VS2005Tip,VS2008Tip

Did you know… You can press Ctrl+Shift+C to jump to the Class View? – #346

Going back to basics with some tool windows I haven’t covered yet.

Pressing Ctrl+Shift+C in the General Development Settings will open the Class View. The Class View is in theory a lighter weight version of the Object Browser (your scope search is limited to just your solution), but the two mostly exist due to historical reasons when the IDE as we know it was being merged in the 2002 era.

Class View

The command to view the Class View is View.ClassView in case your keybinding vary.

View.ClassView command in Tools Options

Technorati Tags: VS2005Tip,VS2008Tip

Did you know… You can launch VS without the splash screen (/nosplash), and maybe even save some time. – #345

According to some blog posts, this tip should save you some time using Visual Studio 2005. I’ve asked around and I think it loads Visual Studio 2008 slightly faster because there’s no pause for you to read the splash screen.

from cmd line, run devenv.exe /nosplash

and enjoy a splash screen free launch.

image

Technorati Tags: VS2005Tip,VS2008Tip

PDC Day 0 Pictures

told myself as soon as i finished uploading these pictures, i can grab breakfast. Hopefully i have just enough energy to make this understandable. =D

I attended the WomenBuild event and sat next to Frank Arrigo.

Frank Arrigo building legos

I had to take pictures of the people taking pictures.

WomenBuild people taking pics of legos

The picture below is my Lego representation of Super Mario World’s Luigi character depicted in Silverlight.

Super Mario World Luigi in Lego Silverlight

After the event, i went to the book store to see my book on the shelf for the first time.

me at PDC book store with book

After dinner with Doug Holland and C++ MVP Carl (didn’t catch your last night), Beth Massi and Yag and I went out to Howl at the Moon. The piano player was cheering Geaux Saints, so i knew he had lived in New Orleans at some point. So, i requested the Mardi Gras Mambo in my New Orleans honor. He says, “oh, i’ve been called out.” He did a great job.

Thanks to Yag, I was word of the day to celebrate the book.

Howl at the Moon

I so need a new camera.

me at howl at the moon

Now off to grab food…

Did you know… How to deal with sometimes single monitor, sometimes multi monitor displays? (/resetsettings switch) – #344

The best tips come from customer questions that I can actually answer.

In England (or was it Mississippi, it’s been a long summer), a customer had asked me about what to do when at home he’s got a single monitor display, but at work has a multiple monitor display. If you’re using either the same settings files (or more likely the same laptop or VPN’ing in), you could have your window layouts go a little crazy.

First thing you can do is create two different settings files. Setup the window layouts how you want them in the single monitor mode, then go to Tools – Import / Export Settings, and Export just the Windows Layouts. Call the file SingleMontior.vssettings.

Window Layouts category

Now setup the window layouts exactly how you want them in the multi-monitor mode (of course, this requires you to actually be on the multi-monitor computer…) and call this file MultiMonitor.vssettings.

When at home, you can do a Tools – Import/Export Settings – Import to the SingleMonitor.vssettings or at work import the multi monitor settings file. But, there’s one more thin you can do.

There’s a command line switch /ResetSettings that I totally forgot about. (Sorry).

devenv /resetsettings help

If you do just a devenv /resetsettings, then VS will reset to the last file you last reset to (or picked at first launch), despite the “VS is configuring for first time use.” Specifying a file name is much more interesting. Here you could do a devenv /resetsettings SingleMonitor.vssettings for example.

So at home, create a new Desktop shortcut, called VS Single Monitor with the Target as “<drive:>\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\devenv.exe" /resetsettings SingleMonitor.vssettings. And at work create the MultiMonitor version.

image

Now you just have to launch the right shortcut, and you’re good to go.

Technorati Tags: VS2005Tip,VS2008Tip

Did you know… You can create file or item templates – #343

Alongside project templates, you can create item templates within the same File – Export Template wizard. I won’t spend too much time here as much of this information is repeat from how project templates work.

Instead of choosing Project Template, choose Item Template in step 1 of the wizard.

Item template option

On the second page, you’ll choose which file to create as the template

Select item to create as template checbox treeview

Then you can specify which references to include for that file.

image

And the rest are similar to the Project Templates, where they live, what customization options there are.

Technorati Tags: VS2005Tip,VS2008Tip

Did you know… How to change the default templates that appear in the New Project Dialog? – #342

All the tips thus far have been for project templates created by you or someone else. Let’s say you want to make a modification to an installed template, like remove some of the default ones from appearing. Or even adding one to the Program Files directory for anyone on that computer to use.

image

Since this involves modifying your Program Files directory, I strongly advise doing this at your own risk, as you’ll need administrator privileges anyways.

The installed project templates are located at

C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\ProjectTemplates

If you want to remove the Office template from the C# New Project Dialog

  1. Move the Office folder found in the C# folder somewhere else.
  2. Close all instances of Visual Studio.
  3. from cmd line, run devenv.exe /installvstemplates  (Wait until the devenv.exe process in Task Manager finishes.)
  4. launch VS

If you launch VS before step 3 completes, none of your default project templates will appear and you will the following error message when you try to open the New Project Dialog.

image

If you get this warning. Try steps 3 and 4 again, but wait for devenv.exe to finish running in Task Manager. (and make sure all instances of VS are closed).

Technorati Tags: VS2005Tip,VS2008Tip

Did you know… What unchecking the display an explorer window on the Export Templates Wizard does? – #341

It’s a option, so it is fair game as a tip. Hey, they all can’t be winners, you know. =)

Although I find it interesting that it is referred to as a generic explorer window. Are there other types of explorer windows that you can use to override Windows Explorer, like different desktop utilities?

Display an explorer window option

If you uncheck this, you will not see this popup.

Windows Explorer displaying the template .zip file

Technorati Tags: VS2005Tip,VS2008Tip

Did you know… How to import your project template if you chosen not to automatically import it? – #340

On the File – Export Template Wizard, there’s the option to Automatically import the template into Visual Studio.

Automatically import template option

Let’s say that you uncheck this and want to import your project. To me at least, it isn’t completely clear what your next steps would be. Here’s what you need to do.

  1. Go to the Output Location shown about the checkbox, which is probably the default of My Documents\Visual Studio 2008\My Exported Templates. Note that I have the Exported in bold.
  2. You’ll want to copy this .zip file to My Documents\Visual Studio 2008\Templates\Project Templates (or whatever you have specified in Tools – Options – Projects and Solutions – General).

Of course, you could change the tool option setting to point to the Exported Templates, but then if you get any other templates from online or others, you’ll have to put it into the “my exported templates” folder. I guess it is a classic robbing peter to pay paul scenario.

Technorati Tags: VS2005Tip,VS2008Tip

Did you know… you can specify the project icon for your template to appear in the New Project Dialog? – #339

On page 2 of the File – Export Template wizard, you can specify several options. The first of these is how to set the icon.

Export Template Wizard selecting the ya'll icon

Now when you go to New Project Dialog, you can see the icon:

New Project Dialog showing the ya'll icon

I should never be hired as a graphics designer.

Technorati Tags: VS2005Tip,VS2008Tip