Did you know? IntelliSense Everywhere (Lisa Feigenbaum)

Did you know? IntelliSense Everywhere (Lisa Feigenbaum)

  • Comments 16

I've decided to start a "Did you know?" series with tips & tricks. First off is my favorite IDE feature in VB2008: IntelliSense Everywhere! Did you know about all the new places where you can now find intelliSense in VB2008? If you're like me, once you try 2008 IntelliSense you won't be able to go back to 2005.

VB's mission statement is to be the most productive tool for building .NET-connected applications. The VB IDE tools certainly support this point, with intelliSense in particular. Here's a list of ways that intelliSense can make you more productive:

  • Faster typing: IntelliSense word completion helps you to save keystrokes.
  • Fewer errors: IntelliSense prevents coding errors by presenting valid options for the current context.
  • Less search time: IntelliSense saves you time by showing valid member names in a list.
  • Discoverability: IntelliSense helps you figure out what to code next by showing what's available.

But rather than listening to me tell you why it's so great, wy don't you try it out yourself? See the list of categories and images below, of all the new places where you can find VB IntelliSense in VS 2008.

KEYWORDS

At the file level...

Look at all that Visual Basic language help right in the IDE! Who needs to F1 anymore? :) j/k

Look at all that help on the Visual Basic language, right in the IDE! Who needs to F1 anymore? :) j/k

At the declaration level...

Save time typing all those *long* keywords in the Visual Basic language!

Use IntelliSense to write error-free declarations. For example, properties cannot be declared at the file level. (If you tried to declare one there, you would get a compiler error.) Thus, when you invoke intelliSense at the file level, "Property" will not appear in the list:

However, properties *are* allowed at the class level, so if you try to declare a property within a class, the keyword *will* appear in the list:

 

Mid-line verification works as well. For example, properties cannot be declared "MustInherit". Thus if I type MustInherit and then invoke the list again, "Property" will no longer appear:

 

IntelliSense is a great tool here, to help you write grammatically correct code! It eliminates the extra burden of having to keep all these rules in your head.

At the method level...

As you probably expect by now, keyword intelliSense works here too! Here are just a couple examples:

 

 

IDENTIFIERS (NAMES OF VARIABLES, METHODS, TYPES, ETC.)

At the beginning of the line...

IntelliSense now appears at the beginning of a line. The example above showed keywords in the IntelliSense list at the beginning of a line within a method-body. However, identifiers appear there too. Here are a couple examples...

You can now use intelliSense to remember your method names:

 

Assigning various members off an instance isn't so tedious anymore, when you don't have to keep typing out the instance name! (see below)

 

 In an expression...

There are *many* expression contexts in the Visual Basic language, and now you can enjoy enhanced IntelliSense support in *all* of them. Below are some examples.

After Equals:

After a binary operator:

Argument to a function call:

After Return + Space in a function. (Don't worry about remembering all your local variable names when writing the Return statement for your function anymore - IntelliSense will do the remembering for you.)

Within a statement:

Etc., etc., etc. There are so many places where the new VS2008 intelliSense appears, that it is not possible to detail them all... But I hope this this list will give you an idea.

Happy coding!

Leave a Comment
  • Please add 5 and 8 and type the answer here:
  • Post
  • :-) Siempre me he sentido más cómodo escribiendo código C# que VB dentro del IDE de Visual Studio 2005

  • I was looking at Lisa's latest blog entries , and the second last screen shot made me sit back and

  • Hi Lisa,

    I stumbled on a weird behaviour this weekend and it seems I'm not the only one to have encountered it:

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

    Do you have some insight about this issue?

    Is it really a problem or does it have something to do with the new type inference or a new feature that is on by default for a .net 3.5 project?

    I was coding up a sample that demoed the correct usage for the boolean type and Intellisense let me down on this one :-(

    DM

  • Excellent article.  The examples show that VB 2008 IntelliSense is definitely better than VB 2005.

  • Hi DM,

    Thanks for raising this. Yes, I've seen it on the forums too. I've replied here:

    http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2658667&SiteID=1&mode=1

    This issue is addressed in VS2008 SP1. I'm sorry for the inconvenience - and especially for the demo moment! :)

    Cheers,

    Lisa

  • Lisa Feigebaum from the VB team recently wrote two posts about VS2008 IntelliSense for Visual Basic.

  • Lisa Feigenbaum from the VB team has a bunch of "Did You Know?" facts about Visual Basic that will help

  • Lisa Feigenbaum from the VB team has a bunch of "Did You Know?" facts about Visual Basic that

  • I just arrived back from my trip from Asia, and decided to celebrate (since I'm jet-lagged and can't

  • I just arrived back from my trip from Asia, and decided to celebrate (since I'm jet-lagged and can't

  • I just arrived back from my trip from Asia, and decided to celebrate (since I'm jet-lagged and can't

  • How can i change font size and shape of intellisense in Visual Basic 2008

  • Links 24/Jan: ASP.NET, ASP.NET AJAX, Visual Studio, .NET, IIS

  • 【原文地址】 Jan 24th Links: ASP.NET, ASP.NET AJAX, Visual Studio, .NET, IIS 【原文发表日期】 Thursday, January 24

  • ASP.NETMVC框架路线图更新

    【原文地址】ASP.NETMVCFrameworkRoad-MapUpdate

    【原文发表日期】Tuesday,February12,200...

Page 1 of 2 (16 items) 12