Why Sandbox solution will not support Visual Webpart ?


Why Sandbox solution will not support Visual Webpart

The standard Visual Web Part is not supported in the sandbox environment. The reason for this is because Visual Web Parts effectively host an ASCX user control within the Web Part control. The ASCX file is deployed to the _controltemplates virtual directory in the physical file system on each Web front-end server. The sandbox environment does not allow you to deploy physical files to the SharePoint root, so you cannot use a sandboxed solution to deploy a Visual Web Part based on the Visual Studio 2010 Visual Web Part project template.
A Visual Studio Power Tool is available that addresses this issue. A Power Tool is a plug in for Visual Studio. The tool will generate and compile code representing the user control (.ascx) as part of the assembly. This avoids the file deployment issue. You can download a Power Tool for Visual Studio 2010 that supports Visual Web Parts in the sandbox from Visual Studio 2010 SharePoint Power Toolson MSDN.
Advertisements
Posted in Sharepoint 2010 Web Parts | Leave a comment

SharePoint 2010 Content Organizer


SharePoint 2010 Content Organizer

Download & View

http://www.youtube.com/watch?v=jZ69yEF5j8s&feature=player_embedded#!

Posted in Sharepoint 2010 Client Object Model | Leave a comment

Consuming SharePoint 2010 Lists Data in the SSRS 2008 R2 Reports


Consuming SharePoint 2010 Lists Data in the SSRS 2008 R2 Reports

Step 1: Ensure that you have a SharePoint List.
In this demo, we will report against SharePoint Products List.
Step 2: Understand the SharePoint List Web Service Interface.
SharePoint has a lists.asmx web service which provides interface to download the SharePoint lists data in the non-SharePoint systems. You can access the SharePoint list web service using the http://siteurl/_vti_bin/lists.asmx. You can use the GetListItems method which returns dataset to download all the list items for the specific list.
Step 3: Create new Shared Data Source and Report Server Project
Create a new Report Server Project in the Business Intelligence Development Studio (BIDS). First step of configuring the SSRS report is creating the new shared data source. Select the SharePoint List as a data source type and specify the SharePoint Site URL hosting the lists for the connection string.
On the credentials tab, specify either windows authentication or no authentication if anonymous authentication is enabled on the SharePoint Site. Please do no select any other options. None of the other options would work for the SharePoint List Web Service.
Step 4: Create a new Report.
Next steps would be creating the report specific data source and data set to configure the data for the report. Make sure Report Data pane is available in the designer.
Step 5: Create a new Report Data Source.
Using the Report Data pane, create the new report data source. Specify the Shared Data Source as a report data source.
Step 6: Create a new Report Data Set.
Using the Report Data pane, create the new data set. Specify the Report Data Source as a data source. New Query designer support for the SharePoint Lists as a data source, allows the developers (from the BIDS tool) or end users (from the Report Builder tool), browse through the SharePoint lists, select the specific list, and define the filters and parameters without knowing detailed SOAP or CAML query language. As stated earlier, one of biggest limitations of this approach is SharePoint Lists as a data source doesn’t support selecting data from the multiple lists. One way you can avoid joining multiple lists is define the list relationships and bring the additional fields along with lookup column. For more complex joins, you can create the custom web service. Custom web service requires XML as a data source and specify the SOAP command to retrieve the data from the SharePoint Web Service in the query designer.
Here is the sample Query to access the web service through the SharePoint SSRS data interface
<RSSharePointList xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xmlns:xsd=”http://www.w3.org/2001/XMLSchema“>   <ListName>Product</ListName>   <ViewFields>     <FieldRef Name=”Title” />     <FieldRef Name=”Product_x0020_Line” />     <FieldRef Name=”Product_x0020_Description” />   </ViewFields>   <Query>     <Where>       <Contains>         <FieldRef Name=”Title” />         <Value Type=”Text”>           <Parameter Name=”Title” />         </Value>       </Contains>     </Where>   </Query> </RSSharePointList>
Step 7: Validate the fields returned by the Data Set
In the Query designer, you can verify if query is valid and returns the fields.
Optionally, you can click on the fields tab on the data set to see if query returns the data fields contained by the data set.
Step 8: Design the Report and Preview the Report in BIDS
Once you have properly configured the data source, data set, and fields, you can design the report by dragging and dropping the fields on the report designer. In this scenario, we will create a simple tabular report and preview the report to make sure reports renders fine in the BIDS before publishing to the SharePoint.
Step 9: Deploy the Report to the SharePoint
You can use the BIDS or upload the RDL files to the SharePoint Document Libraries directly.
Step 10: Verify the SSRS Report in the SharePoint You can use Report Viewer or Report Explorer web parts if SSRS is installed in the native mode to consume the SSRS reports in the SharePoint. Alternatively, you can use the SharePoint SSRS integrated mode to create and consume SSRS reports more collaboratively by enabling the SSRS report content types in the document libraries. In this scenario, we have SharePoint Integrated environment and SharePoint document library is enabled to host the SSRS reports.
Posted in SSRS Reports | Leave a comment

Download Microsoft SharePoint Designer 2010


Download Microsoft SharePoint Designer 2010

Posted in Sharepoint 2010 Designer | Leave a comment

Create termstore using Object model


Create termstore using Object model

public override void ItemAdded(SPItemEventProperties properties)
  {
 base.ItemAdded(properties);
  if (properties.ListTitle == “Projects”)
   {
    if (properties.ListItem.Folder != null)
     {
  string FolderName = properties.ListItem.Folder.Name;
SPSecurity.RunWithElevatedPrivileges(delegate()
   {
using (SPSite osite = new SPSite(properties.SiteId))
  {
 TaxonomySession taxonomySession = new TaxonomySession(osite);
 TermStore store = taxonomySession.TermStores[“Managed Metadata Service”];
            Group group = store.Groups[“Neo Metadata”];
    TermSet productsTermSet = group.TermSets[“Projects”];
      productsTermSet.CreateTerm(FolderName, CultureInfo.CurrentCulture.LCID);
    store.CommitAll();
}
     });
    }
     }
    }
Posted in Sharepoint 2010 Fast Search | Leave a comment

Visual Studio IDE


Visual Studio IDE

CodeRun Studio: A free, cross-platform browser-based IDE

CodeRun Studio is a cross-platform Integrated Development Environment (IDE), designed for the cloud. It enables you to easily develop, debug and deploy web applications using your browser.
CodeRun Studio can be used instead or alongside your existing desktop IDE. You can upload existing code in order to test it in the cloud or for sharing with your peers.
CodeRun Studio is a free service.   Try It Now!

CodeRun Studio Features

Create projects in multiple languages

CodeRun features native support for C#/.NET (3.5), PHP (5.1), JavaScript, HTML and CSS. C# support includes ASP.NET, WCF, Silverlight and WPF browser application development and deployment. Database support includes SQL Server 2005 and Amazon SimpleDB. This means you do not have to learn anything new in order to begin working with CodeRun. Simply upload you existing code, or start from one of the built-in templates.

Manage your code solutions, projects and files online

CodeRun fully supports opening and editing Visual Studio® solution/project files, along with folder-based websites. If you wish, you can download your code, and continue editing it offline. When you are done, you can upload your new code to test it online.

Edit code with syntax coloring and code-completion

CodeRun features real-time syntax-coloring and automatic code-completion to assist you during development. Code-completion options can be filtered by member type, so you can easily search for properties, fields, methods and events. XML comments and documentation appear as tooltips, so that everything you need to know is exactly where you would look for it.

Compile code and review build errors

CodeRun features native compilation for Microsoft .NET managed code applications. Compilation is swift as CodeRun utilizes powerful cloud servers. The output console and error list window reports the standard messages, just as you are used to with your desktop IDE.

Run and debug code in multiple platforms

CodeRun features a powerful online debugger. You can use your browser to step through server code, add breakpoints, inspect the call stack and add watch items. Since you can also choose to share your code, you can easily allow others to debug your code, which can be a huge time-saver!

Share code with hyperlinks

If you choose to, you can easily share your code with your fellow developers. When you share code with CodeRun, your project is assigned with a unique URL that you can send to others. Anyone who navigates to your link receives a separate, fully modifiable and runnable version of your code.
Watch a short video: Sharing code with CodeRun

Language / platform feature support Matrix

CodeRun Studio is rapidly evolving, adding support for new languages and platforms. If you are missing a feature that you would like to see, please let us know.
CodeRun currently provides the following language/platform feature support:
Language / Platform Syntax Coloring Code Completion Compilation Server Side Debugging Hyperlink code sharing Single Click Deployment
C# / ASP.NET Yes Yes Yes Yes Yes Yes
C# / WPF Yes Yes Yes Yes Yes Yes
C# / Silverlight Yes Yes Yes Yes Yes Yes
PHP Yes No N/A No Yes Yes
JavaScript Yes No N/A No Yes Yes
HTML Yes No N/A No Yes Yes
CSS Yes No N/A No Yes Yes

About security and privacy

CodeRun was designed to deliver a secure and private development environment, similar to conventional desktop IDEs. All the code you write is private by default and can only be accessed by you. During development, your code executes in a temporary sand-boxed environment, in which you are the sole administrator. When you deploy your application to a hosted site on CodeRun, the application itself is publicly available, while your code remains private.
In addition, CodeRun provides great features to allow you to share your runnable code with your fellow developers if you decide to do so. As owner of a shared project, you can control read/write permissions of the people you choose to invite. You can also choose to make the project open source and available for everyone.
Posted in Sharepoint 2010 Fast Search | Leave a comment

Set Custom Master Page for All subsites using Poweshell Command


Set Custom Master Page for All subsites using Poweshell Command

Set Custom Master Page for All subsites
$site = Get-SPSite http://serverurl/
$site | Get-SPWeb -limit ALL | ForEach-Object {$_.MasterURL =  “/_catalogs/masterpage/custom.master”;$_.Update()} $site.Dispose()
PS C:\Users\Triad> Get-SPWeb -identity http://serverurl/ | Format-T able -property MasterURL
MasterUrl ——— /_catalogs/masterpage/Custom.master
PS C:\Users\Triad> Get-SPWeb -identity http://serverurl/ | Get-Memb er
   TypeName: Microsoft.SharePoint.SPWeb
Name                                  MemberType Definition —-                                  ———- ———-
AddApplicationPrincipal               Method     Microsoft.SharePoint.SPUser… AddProperty                           Method     System.Void AddProperty(Sys… AddSupportedUICulture                 Method     System.Void AddSupportedUIC… AllowAllWebTemplates                  Method     System.Void AllowAllWebTemp… ApplyTheme                            Method     System.Void ApplyTheme(stri… ApplyWebTemplate                      Method     System.Void ApplyWebTemplat… BreakRoleInheritance                  Method     System.Void BreakRoleInheri…
Posted in Sharepoint 2010 Server Object Model | Leave a comment