Skip to main content

Posts

Step by step BCS in SharePoint2010

Hi friends, Through this blog I am going to share the e-Book on BCS in Sharepoint2010 which guide you in development for Business Connectivity Service in sharepoint2010.This books contains everything about BCS  with screens and real scenerio examples. Vijai Anand (Author of this e-book) have covered all possibles scenerio which required for BCS. Below are the Contents in this e-book: 1 Business data connectivity services: an overview 2 Configure business data connectivity services 3 Configure BCS service application association

SharePoint Branding Solution Pack using VS2010

Introduction Today, in this blog I am trying to provide you the Custom Branding solution Pack. This solution pack will save time and effort while developing the custom sharepoint with publishing sites in sharepoint. It works great. So, we all are good to go and use this re-usable solution pack. Description The source code shows how to prepare a structure for Sharepoint Branding solution. This pack contains : Master Page Gallery structure Page Layout Gallery structure Image Gallery Styles Library gallery Event Receiver

Tips n Tricks:Store Reusable code in Visual Studio

Hi friends, Through this articleI just want to share some tricks that we already have in visual studio. While doing development we always need some code/snippet that we are using regularly and to use the same code either we do copy and paste or we are writing the whole code again. We can achieve the same by below tricks: Hope you enjoy the article. This will be time saving for you.

Consistent SharePoint 2010 branding for Mobile browsers

Through this article I am going demonstrate you how to make consistent UI in sharepoint2010 in different mobile browsers. My mates every time asking me why we need to involve mobile device with SharePoint. Through this article I am just giving the sample where I am showing why we are slowly moving to mobiles from PC. While giving demo on "SharePoint on mobile" to client I found below things: Client want everything on their hand, means on mobile (Bcoz of busy schedule no time to open laptop/system) Client doesn't want to compromise with UI. Application should as simple and easy to use. Application should be scalable and easy to extend in future. Out of all four, below three is already provided by SharePoint. SharePoint is lacking somewhat in First point.  But as I said we developer can do anything so here we can do the same "We will bind the SharePoint without breaking SharePoint Rules". I am using safari browser for the demonstration because thro...

Create Custom hit counter in SharePoint2010 using Sandbox Solution

In this blog I am going to demonstrate how to create Hit counter for SharePoint site with user details using sandbox solution. I took reference from codeplex code( http://hitcounter.codeplex.com ) which is sharepoint2007. I modified his sample and tried make it simple and easy for you. Once you understand the way I created then its very simple for you to make any further modification depends on your requirement. This solution will be very useful when you need detail about the person who visit this page and also about the number of time page view with page detail. I created this solution that will make your work easy. It's very simple where you don't need to do anything except deploying the feature and adding the web part into you master page or layout page in sharepoint2010. Below is the screenshot that will display the how it looks like:

Code for language translation

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML xmlns:o> <HEAD>   <TITLE>Gujarati translation-Ravishankar</TITLE>    <script type="text/javascript" src=" http://www.google.com/jsapi"></script >       <script type="text/javascript">       google.load("elements", "1", {       packages: "transliteration"        });       function onLoad() {      var options = {       sourceLanguage:        google.elements.transliteration.LanguageCode.ENGLISH,       destinationLanguage:        google.elements.transliteration.LanguageCode.GUJARATI,       shortcutKey: 'ctrl+g',       transliterationEnabled: true ...

Create a Web Part Page with a Web Part in Sharepoint 2010

Source code from codeplex In this blog I am going to explain how to create a web part page along with a web part. After using this feature, we just need to activate the feature; the rest will complete automatically. Steps for creating the functionality: Step 1: Create a project with Farm-Based solution: Step 2: Add a new item as webpart: Step 3: Add feature event receiver class, your solution should look like the following: Step 4: Add your logic to the web part: 01 [ToolboxItemAttribute( false )] 02 public class CustomWebPart : WebPart 03 { 04 protected override void CreateChildControls() 05 { 06 LiteralControl lt = new LiteralControl(); 07 lt.Text = "This webpart automatically added with page" ; 08 this .Controls.Add(lt); 09 } 10 } Step 5: You need to provide logic in the feature Reciever class. Find the attached file to see the source code. Step 6: Build, deploy and activate the feature. Step 7: Go to Page library ( S...

How to create Sandbox solution with full trust Proxy

Download Files: CustomSBFullTrust.zip In this article I am explaining the step by step procedure to create a sandbox solution with full trust proxy. Before starting I am assuming you are aware of the sandbox limitations. Full trust solution is providing sandbox solution to work in a full environment. In short this is the way to achieve farm based solution functionality in a Sandbox. Namespace Required: using Microsoft.SharePoint.UserCode; using Microsoft.SharePoint.Security; using System.Security.Permissions; using Microsoft.SharePoint; using Microsoft.SharePoint.Publishing;

SharePoint Language translator web part using Sandbox

Download Files: Ravishankar.TranslatorWebPart.zip In this article we will see how to create a language translator webpart using sandbox. If you read my previous articles on language translator then it will be easy for you to understand. Before writing this article I also searched much but I didn't find a solution/web part that explains the procedure for creating a language translator in sandbox solution. As we know the limitation of a sandbox so you fill find very rare article on Language translation using sandbox web part.

How to create Publishing Page based on page layout in sharepoint2010

Hi Friends, This blog will help you when you need to create pages in based on page layout.You just need to use the below common method. private void CreatePublishingPage(string absoulteUrl, string pageName, string pageLayoutName, bool isLandingPage) { using (SPSite Osite = new SPSite(absoulteUrl)) { using (SPWeb oWeb = Osite.OpenWeb()) { string fullPageUrl = string.Empty; PublishingWeb publishingWeb = PublishingWeb.GetPublishingWeb(oWeb); /* Get the publishing web page collection list. */ PublishingPageCollection publishingPageCollection = publishingWeb.GetPublishingPages(); //GetPageLayoutName(application); if (!string.IsNullOrEmpty(pageLayoutName)) { /* Search for the page layout for creating the new page */ List layouts = new List (publishingWeb.GetAvailablePageLayouts()); PageLayout pageLayout = layouts.Find( delegate(PageLayout l) { return l.Name.Equals(pageLayoutName, StringComparison.CurrentCultureIgnoreCase); }); /*page layout exists*/ if (pageLayout ...

How to create a language translator using Google's API and JavaScript

Download Files: LanguagetranslatorusinggoogleAPI.zip In my previous article , I only explained how to create a language translator with http request. In this article I am going to explain how to create a language translator using GToogle API and JavaScript. As a Sharepoint developer I am expecting whatever code I am trying to work everywhere and in all environments. So I found JavaScript is the best way to write the code. The Google API is has more options compared to Microsoft's translator and we can use this script wherever we want. I tested the code in creating the sharepoint webpart and an ASP.Net application. The following is the screenshot of my application: If we take a close look at my application you can find, I have created a translator in three ways: Using HTTP handler (Already explained in my previous article) Using SOAP method Using JavaScript with Google API I am going to explain one in this article below. You can find all three ways in my solution that I ha...

Installation and configuration for FxCop tool

Today I am going to explain about the installation and configuration for fxcop tool. Description about tool: FxCop is a tool that performs static code analysis of .NET code. It provides hundreds of rules that perform various types of analysis. Design Globalization Interoperability Maintainability Mobility Naming Performance Portability Reliability Security Usage Below are the steps for Installation and configuration of FxCorp tool:

Create Language translator using ASP.NET

Below screenshot will be the example where you can see the text that we write on text box will convert into selected language. To translate text into multiple language we need to call webservices.There are multiple number of service code available in google so it will not be a problem.you can select anyone and can create for your site.

Programmatically create web part for mobile in SharePoint2010

In SharePoint 2010 all mobile devices are redirected by default to the mobile SharePoint rendering engine. The mobile rendering engine of SharePoint provides mobile users access to the sites with a completely stripped interface. Its main function is to list all libraries and to provide basic access to them. 1. Create a Visual Studio 2010 Visual Web Part Project

Create Personalize Application toolbar in SharePoint 2010

In this article I am going to explain about the application toolbar which will display the applications based on the current login users. To achieve the requirement we need to create two custom lists i.e. "All Apps" and "User App" " All Apps" list will have the below columns: " User Apps " list will have the below columns:

Custom Sandbox Application Page in SharePoint2010

From my previous article for " Reference web part in SharePoint 2010 ", I am extending the same sandbox solution with this article. So you just need to download code for sandbox web part and follow the steps below. The Sandbox in SharePoint 2010 allows Site Collection administrators to upload solutions in their Site Collections without access to the physical server. Sandbox Solutions do have some limitations, for instance we cannot add new application pages. Application pages are normally pages added to the _layouts folder, which are located in the 14 hive\TEMPLATE\LAYOUTS physical folder on each server. Sandboxed solutions still allows us to upload Content Pages; that is pages that are located in a document library for instance. The following are the steps to create a custom page in sandbox solution. 1. Create a project

Reference webpart in SharePoint 2010

In this article I am just going to explain how to create a reference webpart programmatically. Requirement: Need a webpart that display all pages title with link. Only related page should display in the link. Webpart should be added in all pages. Same page should not have hyperlink. In other words the query will return the page where the webpart is present. But it should have Hyperlink only with other pages. Namespaces : using Microsoft.SharePoint; using Microsoft.SharePoint.WebControls; using System.Text.RegularExpressions; using System.Text; Logic: using (SPSite site = SPContext.Current.Site)             {                              using (SPWeb web = site.OpenWeb())                 {      ...

Form Based Authentication in MOSS2010 Against SQL Server Database

Configuration: Step by step screenshot for FBA implementation In SQL: Create one web application for membership: Create Web Application(example moss:1111 and extend this application to http:// moss:1112 for From-based authentication) Changes in Web.config

How to use Mobile Entree Excel Addin in SharePoint 2010

Description : In this article I will just explain how to use Mobile Entree Excel Addin (SharePoint BI)  in SharePoint 2010 with sample example. Install Excel Add : To install the Excel AddIn go to the site, click on Mobile Entree Configuration->Global Config Excel Addin : After installation of Mobile Entree AddIn, we will get an option in Excel under "Insert" section named "Mobile View Configuration". This AddIn will help you to set a view when we open Excel in a mobile browser. Following are the steps for creating Mobile view in Excel: Step 1 . Create New DashBoard. Give it a name such as "My Dashboard".