Loading...

Thursday, November 25, 2010

Synchronizing User Profiles With Site Collections In Webapplication

Command for Synchronizing User Profiles With Site Collections In Webapplication

To Modify the user profile , Go to Shared Service Provider site --> User Profile and Properties-->Edit User info

run the following commands.

STSADM -o Sync -synctiming M:1


STSADM -o sync -sweeptiming M:1

After 1 minute login with modified User

Wednesday, November 17, 2010

QuickLinks in Sharepoint

In this post , I will enlist the Quick links in Sharepoint.

While resolving any bug or developing any functionality you should keep hawk eye on urls generating in browser .Its like a clue to a issue, many times.

To Get the Webparts maintenance page

http://server/pages/default.aspx becomes http://server/pages/default.aspx?contents=1

To Get ServerTemplateID
http://server/_vti_bin/owssvr.dll?Cmd=ExportList&List=9e7d064f-d9c8-42f0-8a4f-b02c9f4c259f


To Get ContenttypeID
view in browser while modifying content Types
/_layouts/ManageContentType.aspx?ctype=0x010070A9BD7BBA699D48B92FE21F1632CC28.

Some more to be added

Sunday, October 10, 2010

Fundamentals of Site Definition

Here I will add  details on following Placeholders (with respect to SP2007/2010)
Site definition is defining the site with prefigured set of Sharepoint Objects

1)How to provision Pages with Master Page ,Page Layouts ,Images and CSS,
1)Define the feature for Page which combines Pagelayouts   and Webparts  and other contents  of the page  as follows


Elements.xml
(Define all the pages with GhostableInLibrary  attribute, which makes pages available in site)


<module Name="WelcomePage" Url="Pages" Path="Pages">
<file Url="Welcome.aspx" Path="page.aspx" NavBarHome="True" Type="GhostableInLibrary">
<property Name="Title" Value="Welcome" />
<!--<property Name="PublishingPageLayout" Value="~SiteCollection/_catalogs/masterpage/VillageLayout.aspx,Custom Layout" />-->
<property Name="PublishingPageLayout" Value="~SiteCollection/_catalogs/masterpage/CustomLayout.aspx, Custom Layout" />



Feature.xml
Define the Web Scoped Feature
  define the feature  for the Pages in following  path of solution
solution Name\Site Definations\12\TEMPLATE\FEATURES\WebPages\Pages

Stapple this feature  with   Feature Stappler
Feature Stappler is the Farm level feature which associates Site  Template  with Feature Id  in its elements.xml
as follows

<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<!-- Master Page Files -->
<FeatureSiteTemplateAssociation Id="6A4E5195-B0C0-42cb-B4AC-C18E72276A78"
TemplateName="TemplateName#0"/>

<!-- Site -->
<FeatureSiteTemplateAssociation Id="07A8588D-CFB5-46bd-A315-6FA80E31AAA6"
TemplateName="TemplateName#0"/>

<!-- Web -->
<FeatureSiteTemplateAssociation Id="72E6C98A-3E37-4a4a-81F5-504A48A646CC"
TemplateName="TemplateName#0"/>

<!-- Feature Executing at site level -->
<FeatureSiteTemplateAssociation Id="2772D112-519A-43A2-AB91-8FE93B6130BE"
TemplateName="TemplateName#0"/>
</Elements>


Where TemplateName   is  Folder at location
solution name\Site Definations\12\TEMPLATE\XML\SiteTemplates\TemplateName 
Which contains the Onet.xml

2)How to Provision Webparts
In   above elements.xml specify the webparts which are prefigured on  page when site is loaded

<module Name="WelcomePage" Url="Pages" Path="Pages" >
<file Url="Welcome.aspx" Path="page.aspx" NavBarHome="True" Type="GhostableInLibrary">
<property Name="Title" Value="Welcome" />
<!--<property Name="PublishingPageLayout" Value="~SiteCollection/_catalogs/masterpage/VillageLayout.aspx,Custom Layout" />-->
<property Name="PublishingPageLayout" Value="~SiteCollection/_catalogs/masterpage/CustomLayout.aspx, Custom Layout" />
<alluserswebpart WebPartZoneID="g_1D8BB5ABF0A14891B0AC79621A17C840" WebPartOrder="1">
<![CDATA[
<webpart xmlns="http://schemas.microsoft.com/WebPart/v2" xmlns:iwp="http://schemas.microsoft.com/WebPart/v2/Image">
<assembly>Microsoft.SharePoint, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c</Assembly>
<typename>Microsoft.SharePoint.WebPartPages.ImageWebPart</TypeName>
<frametype>None</FrameType>
<title>Site Image</Title>
<iwp:ImageLink>/_layouts/images/homepage.gif</iwp:ImageLink>
</WebPart>
]]>
</AllUsersWebPart>
<alluserswebpart WebPartZoneID="g_D6F8BAF418504B53B37617BC2FFD4A0C" WebPartOrder="1">
- <![CDATA[
<webpart xmlns="http://schemas.microsoft.com/WebPart/v2" xmlns:iwp="http://schemas.microsoft.com/WebPart/v2/Image">
<assembly>Microsoft.SharePoint, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c</Assembly>
<typename>Microsoft.SharePoint.WebPartPages.ImageWebPart</TypeName>
<frametype>None</FrameType>
<title>Site Image</Title>
<iwp:ImageLink>/_layouts/images/homepage.gif</iwp:ImageLink>
</WebPart>


]]>
</AllUsersWebPart>



Tag AllUsersWebPart specifies the Image Webpart to  be loaded on the Page provisioned in above elements
Two important things here
WebPartZoneID="g_1D8BB5ABF0A14891B0AC79621A17C840"  ,this value is to be retrieved from  corresponding Page Layouts, In above case its  to  be retrieved from /CustomLayout.aspx

Second , To get the CData of webpart
Site Actions -->Site settings--->Gallary-->Webpart Gallary-->Copy the xml of webpart and paste into CData  

Next time I will elaborate on following   and pending placeholder Ids'

1)Creating feature for layouts and and associating it with Site definitions
Create   Site Scoped  feature for Layouts at location
solution Name\Site Definations\12\TEMPLATE\FEATURES\PageLayOuts

In elements.xml specify the pagLayouts to be provisioned as follows
>File Url="XYZPageLayout.aspx" Type="GhostableInLibrary"<


>Property Name="Title" Value="Custom Layout" /<

>Property Name="MasterPageDescription" Value="A custom  layout." /<

>Property Name="ContentType" Value="Page Layout" /<

>Property Name="PublishingPreviewImage" Value="~SiteCollection/_catalogs/masterpage/$Resources:core,Culture;/Preview Images/ArticleLeft.png, ~SiteCollection/_catalogs/masterpage/$Resources:core,Culture;/Preview Images/ArticleLeft.png" /<

>!--

>/File<
 
where
XYZPageLayout.aspx  defines the webpartzones and webparts or other Page Contents

2)Associating above Page feature with Site definition 

< Feature xmlns="http://schemas.microsoft.com/sharepoint/"
 Id="Guid"
Scope="Web"
Hidden="FALSE"
Title="Executes when web is created"

Description="Executes when web is created"

Creator="swati"

ReceiverAssembly="fullnamedescription"

ReceiverClass="namespace.classname"

>

< ActivationDependencies >

< !-- Publishing -- >

< ActivationDependency FeatureId="22A9EF51-737B-4ff2-9346-694633FE4416"/ >

< !-- Navigation -- >

< ActivationDependency FeatureId="541F5F57-C847-4e16-B59A-B31E90E6F9EA" / >

< /ActivationDependencies >

< ElementManifests >

< ElementManifest Location="elements.xml"/ >

< /ElementManifests >

< /Feature >
where elements.xml    defines the structure  for Pages  as defined above
which includes xml for defining   layouts ,webparts etc.

3)How to Provision Lists with and Its contents

4)How to associate features with templates

5)How to Control Navigation properties of site from Onet.xml

Details about Implementing Site Definition in Sharepoint 2010

Friday, September 17, 2010

How to Debug Infopath forms running in SharePoint workflow

1)Open the Infopath  form's Project in Visual Studio 2008/Visual studio 2005
 To Get Project's path open Infopath form .And find Design Task -->Design checker -->Compatibility Setting -->Programming -->Project Location

.
2)Run the Infopath forms in workflow.
Copy the dll ,and infopath forms present in bin folder of project location to  12-->Template-->Feature folder of workflow solution -->copy this folder 12 hive (right click -->copy to 12 hive)

Infopath dont generate .pdb files by default .You need  follow as
right click project in solution explorer-->Properties-->Select Build Tab-->Advance--Build settings -->Set Debug Info--full

3)Refresh infopath forms ,In visual studio Tools -- >
Attach to process-->w3p.exe --> Select the Work flow code

Monday, August 30, 2010

What are the best ways to learn sharepoint2010/2007?

1)Try to read articles from Microsoft.Office ,MSDN or Technet completely .
2)Study the 14/12 hive structure and all the aspx pages inside it.grab the keywords from the pages and search on google.
3)Refer the nice books which provide miscellaneous , tricky things and tips
3)Complete all virtual labs.
4)Study for certifications .
6)View and make notes from videos and Screen casts.
7)Refer the SharePoint msdn Quick Notes

Saturday, July 24, 2010

Certification in Sharepoint 2010 for Developers

Any Certifications you do , validates yourself for the skills you have in corresponding technology (Not just reading dumps and passing , but with actual studies :) ).

This post is to inspire you for doing certification in Sharepoint 2010
For Developers
Exam 70-573:
TS: Microsoft SharePoint 2010, Application Development


Good resources for preparing
1)Microsofts Elearning
2)Channel 9 videos
Go through the contents and preapre for exam .All the best!!
If anyone has passed this exam , can share his/her experiance here..

Sunday, June 27, 2010

How to use Jquery in sharepoint development??

Hello All,

      Jquery is the powerful tool for customization and doing the things in much faster way.So its definitely effective , to use Jquery in sharepoint develpment where ever possible.

Work out on this code to start with Jquery and Sharepoint
its shared by Mohamed Mosallem



Click here to get some More Google Image Results

here to get some More Google Results


Visual learning is always effective and faster . So dont miss to view the following videos

Create a Sliding Interface in SharePoint
jQuery For Absolute Beginners
jQuery with Sharepoint - An intro to jPoint Screencast
jQuery and Sharepoint - Search this Page

Learn jQuery with FireBug, jQuerify and SelectorGadget
RSUG Session - JQuery with SharePoint  (1/6)
RSUG Session - JQuery with SharePoint  (2/6)
RSUG Session - JQuery with SharePoint  (3/6)
RSUG Session - JQuery with SharePoint (4/6)
RSUG Session - JQuery with SharePoint (5/6)
RSUG Session - JQuery with SharePoint (6/6)
SharePoint QuickLaunchExtender
SmartTools jQueryLoader Screencast
How to make Piles Of Money with Google, jQuery and SharePoint

Click here to contact the Jquery Guys if you are facing any issue

I think this is enough to digest the jquery in Sharepoint :)