Tag: Solutions

Custom Exceptions Handling

In this post I’ll show how I handle exceptions in the projects I develop.

Some time ago I wrote a simple class which turned out to be very useful in exception handling and displaying it to the user. To use it You have to create a new instance of it and add it to the controls collection on the page. Then You can just add exceptions, through the appropriate method, which will be rendered as a HTML table. The class uses Render event to check if any exception has been added, if so the class renders appropriate HTML code which is shown to the user.

(continue reading…)

Assembla – free svn

Assembla is a free subversion for any types of projects. You can use it to store solution online, follow the changes you made(file versioning), share Your work etc. Using Assembla is free and the only thing You have to do is registering on the site and creating a new space for Your project.

Additionally, with a help of third-party tools it’s possible to extend Your Visual Studio 2005/2008/2010 with ability to manage Your Assembla source code. (continue reading…)

SqlMembershipProvider – Users management

In the previous post I showed You how to manage roles for forms authentication. Now I’ll explain how to manage users from the code side.

The main class which lets You manage users from provider is System.WebSecurity.SqlMembershipProvider class.

To get the SqlMembershipProvider object You have to use System.Web.Security.Membership class and pass the name of the provider You want to obtain: (continue reading…)

SqlMembershipProvider – Roles management

In the previous post I showed You how to create custom log in page for forms authentication. Now I’ll explain how to manage roles from the code side.

The main class which lets You manage roles from provider is System.Web.Security.SqlRoleProvider class.

To get the SqlRoleProvider object You have to use System.Web.Security.Roles class and pass the name of the provider You want to obtain: (continue reading…)

SharePoint 2010 custom login page

If Your interested in custom login page for SharePoint 2013, check this post.

In SharePoint 2010(like in previous versions) You can enable forms authentication along with standard AD authentication. Thanks to that the internal users can log in to SharePoint using theirs domain accounts and external users can use prepared accounts which are kept in the database. Here is very good instruction step by step how to enable this funcionality. (continue reading…)

SPSecurity.RunWithElevatedPrivileges – the way to become a god

Permission levels in SharePoint are very important thing. They define actions which specified users can perform on sites, lists etc. But, in vast amount of applications, there is a way to bypass permission checking and become a “god” who can do almost everything. I’m talking about SPSecurity.RunWithElevatedPrivileges method. This method lets’ You get a reference to the SPSite object and with it You can access any of the site collection elements with administrator rights.

(continue reading…)

log4net and EventLogAppender

Lately in my projects I’ve been using log4net library which enables great way of logging messages and errors in many different ways and on different levels. I won’t describe exatcly how it works, but if You’re interested You can read about it here http://logging.apache.org/log4net/.

(continue reading…)

VSTO Part 2 – Excel Add-In

Second part of the Excel tutorial. In this lesson I will show You how to add a custom task pane to the add-in and how to write information to desired cell in a Excel worksheet.

I will continue to develop solution from Part 1.

(continue reading…)

VSTO Part 1 – Excel Add-In

Have You ever wondered how to create AddIns for Microsoft Office Applications? In this tutorial I’ll show You how to create an Microsoft Office Excel 2007(although, I think there’s no difference with 2010) AddIn with ribbon  and custom task panes with variuos funcionality. This post, as Part 1 of the tutorial, will describe how to create a solution and ribbon with one button.

(continue reading…)

SharePoint Web Services

WSS 3.0 and MOSS 2007 give developers ability to manage it’s resources by Web Services. With their help You can do things like add attachment to the specified list item or add a new user to the site collection. Full list of Web Services can be found here. Exception is SharePoint 2010 which doesn’t provide Web Services(asmx), but it enables communication through WCF(details here).

(continue reading…)

Copyright © 1996-2010 Tomasz Rabiński | zavaz Blog. All rights reserved.
Jarrah theme by Templates Next | Powered by WordPress