Month: May 2007

Obtained MCTS in .Net Framework 2.0 Web Applications

No Picture

I’ve just passed the Microsoft .NET Framework 2.0 – Web-based Client Development exam (MCTS 70-528) with a score of 788. This means that I’m now a Microsoft Certified Technology Specialist.

Read More »

C#: Does dispose run when you are returning inside a using block?

No Picture

Consider the code below. I wanted to confirm that the dispose method on an idisposable object got executed when you returned within an using statement. The anwser is yes: the dispose method runs before execution is passed to…

Read More »

SharePoint: Closing SPWeb and SPSite objects

No Picture

Within both SharePoint 2003 and 2007, SPWeb objects need to be explicitly closed or disposed of. I believe this is because SPWeb and SPSite object use unmanaged code, so .net garbage collection doesn’t ensure that such objects are…

Read More »

C#: Using An Embedded Resource

No Picture

Quicknote: To embed resources in an assembly you need to add the resource to the project and set the resources build action property to “Embedded Resource”. I normally add resources to a seperate folder named myresources (hence the…

Read More »

ASP.NET: Getting Context

No Picture

Reminder: Normally, in asp.net you get context from the current page object, however this is not always possible (e.g. if you are coding a separate dll that does not implicitly have context). To get context from the caller…

Read More »