Freigeben über


How do you find code you need?

I happen to work on the Samples story for Whidbey. We have a ton of code all over that can help you get updated on how to write stuff. For e.g. in the product we have:

  • Tutorials and walkthroughs that show you how to accomplish tasks
  • Code snippets with the framework documentation
  • General samples for the languages such as Scribble and Process controller
  • Large end to end samples such as Duwamish
  • Samples off the web from code project, google, asp.net etc.
  • Quickstarts

If you are stuck and need good code what do you do to find what you need? Do you look in our docs? Do you look in the quickstarts? Let me know, I'm very curious. This feedback will go a ways in helping us provide a better samples story for Whidbey.

Alternatively, what would be your ideal samples story?

Comments

  • Anonymous
    March 09, 2004
    My first stop for help with .NET is always the latest version of the MSDN library. It's got so much stuff in it, that I couldn't understand anyone going anywhere else.

    Basically, if I need help with a certain class or method, I'll search for it in the index, and see what the page for it says. If that's not enough, I'll expand to the Search tab and see what it turns up.

    If that fails me (usually it doesn't, especially with .NET), I then turn to Google or Google Groups. After that, I'm out of luck.
  • Anonymous
    March 09, 2004
    Thanks for the feedback. I assume you look at the local documentation and not the online one? Do you ever look at the sample code? It seems like you are mostly focused on exploring the class/method level docs...
  • Anonymous
    March 09, 2004
    What I would love to see is that when you provide a sample, sometime it's not obvious what the output of the sample is going to be. I've seen a few samples for XmlTextWriter yesterday where I would have loved to see what the actual output of the code was rather than having to copy/paste it to a cs file, compile, run just to make sure it was really what I was thinking.
  • Anonymous
    March 09, 2004
    I would also look in MSDN, and after that if I do not find an example I need (and it does happen) I use Google.

    In the early days, I felt the MSDN search on hte locally installed MSDN library was the best in the business. I am not so sure anymore.
  • Anonymous
    March 09, 2004

    I Google it.. and I normally click on the MSDN articles first in the search result before I click other links.

    If I still can't find it, I go to Google Newsgroups.

    Does MS have any plans of buying Google? ;-)

    -ron
  • Anonymous
    March 09, 2004
  1. google newsgroup
    2. google
    3. code project
    4. msdn
  • Anonymous
    March 09, 2004
    My first stop is the class and method documentation on my local MSDN library. The next step is usually a search of the local MSDN library to pick up all the other documentation areas. Then it is on to google (sometimes with first with site:microsoft.com so as to pick up support articles), then google and google groups.
  • Anonymous
    March 09, 2004
    Google.
  • Anonymous
    March 09, 2004
    I use the MSDN library installed on my machine. I usually just want a quick little sample, just to make sure I'm understanding it correctly. Those are the samples I'd like to see Microsoft invest in. They're right along with the docs, so they're ultra-easy to get to.

    I use MSDN constantly, and look a few times a week at short samples in there. I've looked at the other samples (quickstarts, Duwamish, etc.) a few times in my life.
  • Anonymous
    March 09, 2004
    The comment has been removed
  • Anonymous
    March 09, 2004
    I usually look at the documentation for a specific method first. I find that the code samples in my local MSDN documentation are very valuable. Also the scope of such a sample is often just what I need.
    Duwamisch as a sample solution is good for study, but not for reference.

    If MSDN fails, then Google newsgroups.
  • Anonymous
    March 09, 2004
    I usually start checking the documentation for whichever classes I plan on working with, review the context of that class, and jump in. Then the sample code, then maybe I'll pop down the hall and ask another member of our team...

    when all else fails, I spam an internal alias :)
  • Anonymous
    March 09, 2004
    Typically I know more or less what class/method I want help on, or at least I know some related class. I look it up in my locally installed MSDN library (I tend to refresh it from the MSDN CDs twice per year).

    If the help topic found that way doesn't help directly I tend to look either at the links in the topic's 'see also' section, especially those that lead out of the reference section, or start simply browsing the full class description.

    If that doesn't help it is time to Google. Especially googling for newsgroups (in contrast to 'googling for websites') has proven useful.

    I never try to find help on the online MSDN site, I only use for the articles on 'new stuff'.

    By the way, +1 to Julien Ellie's post: I too have been irritated often by the lack of output of the samples, please add the output of the samples you add.

    And a little story I recently encountered where the current help system fails: The documentation for System.Runtime.InteropServices.Marshal.GetLastWin32Error and DllImportAttribute.SetLastError fail to give a hint that there is a related class hidden far away in a different namespace that is closely related, namely System.ComponentModel.Win32Exception . The first time when I was looking for functionality provided by Win32Exception I ended up writing my own class providing similar features. Who came up with the idea of hiding that class in an, IMHO, utterly unrelated namespace? Well, these things happen, but the docs should at least attempt to fix it...
  • Anonymous
    March 09, 2004
    MSDN documentation is usually the first stop. However, for serious examples I find that the MSDN stuff is too limited in scope or too simplistic. Some more complex/detailed examples would be great

    Google next
  • Anonymous
    March 10, 2004
    One word - Google. Anymore, I pretty much start with Google. Sometimes I'll restrict the site to microsoft.com or codeproject.com.
  • Anonymous
    March 15, 2004
  1. Google
    2. Safari Online
  • Anonymous
    March 17, 2004
    If I am looking for help with a particular method of a .NET Framework class or with a language-specific feature, I will first go to MSDN online. (I install the library locally, but point to the online version both to make sure I have the very latest changes and to keep everything in IE if I also need to refer to a website article. I use the local install for Dynamic Help and if I'm disconnected.)

    If that doesn't work OR if I am looking for an example of how to do something more complex, essentially looking for a sample of a whole user control or algorythm or something, then I will google, but generally ignore usenet and forum postings in favor of articles on the "top 20" .Net/ASP.NET websites.

    The exception is if I am having a "problem" and need to troubleshoot, in which case I find the usenet/forum posts more effective. Depending on the specificity of the error, I may search the Premier KB first, but will generally just hit google first off.
  • Anonymous
    March 26, 2004
    MSDN
    Google
    &
    http://www.google.com/microsoft
  • Anonymous
    March 27, 2004
  1. google
    2. msdn
    3. code project, quick starts, etc.