Wednesday, September 10, 2008 2:45:24 AM UTC #

In my learning journey from earlier this week, I forgot to mention something:

Don't dispose SPWeb or SPSite objects you get from the "properties.Feature.Parent" property. This rule doesn't come from me—I got this information from a reliable source.

So, here's a little visual guide:

code sample with using block - NO

 

image

From my brief survey of CodePlex projects, it looks like most people were following this rule anyway.

Categories: SharePoint
Technorati:
Wednesday, September 10, 2008 2:45:24 AM UTC  #     |  Comments [3]  |  Trackback
Wednesday, September 10, 2008 12:53:51 PM UTC
Dude, you are spending waaay to much prime blogging time on SP. More Awesomeness.
Wednesday, September 10, 2008 12:54:37 PM UTC
*too much*
Wednesday, September 10, 2008 2:08:37 PM UTC
Ha! I'm sorry to say that I already have another 4 SharePoint posts queued up...you're just going to have to sit through.

Point taken though, and yes, I noticed that my blog took a decided turn in recent months. I need to re-invigorate the Awesomeness category (where there is so much potential material). And maybe the PowerShell category.
Peter Seale
Name
E-mail
Home page

Comment (Some html is allowed: a@href@title, b, blockquote@cite, em, i, strike, strong, sub, sup, u) where the @ means "attribute." For example, you can use <a href="" title=""> or <blockquote cite="Scott">.  

Enter the code shown (prevents robots):

Live Comment Preview
Syndication

Search
Posts on this page
Categories
Sites I visit regularly
About

Powered by: newtelligence dasBlog 2.2.8279.16125

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

© Copyright 2008, Peter Seale

Send mail to the author(s) E-mail



Sign In