Monday, February 24, 2014

SharePoint 2010 - List inline editing

SharePoint 2010 - List inline editing

How to enable inline editing on list.
1. Go to the list and click on the List in the Ribbon.
2. Click on the "Modify this View"
clip_image002
3. Go to the button and expand "Inline Editing", click the "Allow inline editing" checkbox on. And click on the OK button.
clip_image004
4. Go back to the list (the modified view) and now there is a little 'create new list item' icon at the button of view.
clip_image006
5. Click on the create new list item icon and a inline form is show. Fill out the required fields and click on the save icon.
clip_image008
6. And vola, you just create a list item through inline editing :)
Change this settings through API
Find the view (SPView) you wish to change and update the InlineEdit property with the text string TRUE
Remember to .Update() the SPView after updating the property.

Thursday, February 13, 2014

Generate Auto increment number of repeating section infopath

1. Open your infopath form.
2. Add an column named is Sr. No in your repeating table/section.
3. Add a textbox control in the column.
4. Right click on textbox say Textbox Properties.
5. Simply add the following formula to the Default Value field,

count(../preceding-sibling::*[local-name() = "YourRepeatingGroupName"])

OR

count(../preceding-sibling::*) + 1



Thursday, February 6, 2014

Move Sharepoint server from Domain to another domain

Move SharePoint server from Domain to another domain

Move/migrate Sharepoint server  from one domain to another domain
Example: Move sharepont fron mumbai domain to chennai domain.
1.       We have to take the backup of all sharepoint databases and all webconfig and if we have any customization.
2.       Need to take the list of web application pool identity Accounts details.
3.       Now Remove the mumbai domain and join to new domain chennai.com
4.       Create the sharepoint account and add that sharepoint Account to the below groups in the sharepoint machine.
Local administrators,WSS_WPG,WSS_admin and IIS_WPG

5.       Now we need to do 3rd step in SQL machine and add the sharepoint Account in local administrator group and  Open the sql management studio and do the following steps
5a. create a new login for sharepoint account and assign the following roles DB creater and security Admin.
               5b.  Give the DB owner permission for the sharepoint account  for all sharepoint DB using user Mapping option in the user Account property.
6.       Now login to the sharepoint server using sharepoint Account and run the following stsadm commands
6a. stsadm.exe –o updatefarmcredentials –userlogin chennai\testspuser –password test@123
6b. stsadm.exe –o updateaccountpassword –userlogin chennai\testspuser –password test@123 -noadmin
6c. stsadm.exe –o spsearch –farmserviceaccount chennai\testspuser –farmservicepassword test@123
6d. stsadm.exe – o osearch –farmserviceaccount chennai\testspuser –farmservicepassword test@123
6e. the below command for SSP
      Stsadm.exe –o editssp –title SSPname –ssplogin chennai\testspuser –ssppassword test@123
Finally restart IIS with noforce

7.       Check that central admin pool and Sharepoint service account are changed using IIS and Service manager.

8.       Now open the central admin and change the all web application pool account and change the site collection administrator credentails

9.       Then migrate the old  domain users to new domain account using the below stsadm command
9a.stsadm.exe –o migrateusers –oldlogin mumbai\testuser –newlogin chennai\testuser -ignoresidhistory

Sunday, February 2, 2014

InfoPath form to upload an image to SharePoint (no code)

InfoPath SharePoint integration can be implemented in several ways. You can integrate InfoPath 2010 with SharePoint 2010 through SharePoint web services, SharePoint workflows, SharePoint event handlers, or by writing code in InfoPath forms that makes use of the SharePoint client object model or the SharePoint server object model.
Where the two latter means of integration are concerned, you will always have to give your form Full Trust to be able to call those two object models.
If you do not want to write code to integrate InfoPath with SharePoint, your best bet is to explore what theSharePoint web services have got to offer.
Where the uploading of images are concerned, you can either write code to upload images to SharePoint document or picture libraries, or you can use one of two web services: 
1. SharePoint Copy web service, or 
2. SharePoint Imaging web service without having to write code.
Both SharePoint web services offer similar functionality, however, the Imaging web service can be used to upload an image to a SharePoint picture library, while the Copy web service can be used to upload an image to any SharePoint document library.
In addition, if you want to create an InfoPath form that can upload one image to a library, you do not have to write code to get such functionality, and you can use either the Copy web service or the Imaging web service to do so.
Because the Copy web service is a bit more involved than the Imaging web service, this article shows you how to use the Imaging web service to upload an image from an InfoPath form to SharePoint. However, the same techniques you use for hooking up the Imaging web service to an InfoPath form using an InfoPath data connection and rules, would apply to the Copy web service.


In the following 4-minute InfoPath 2010 tutorial video, I show you how easy it is to use rules to connect an InfoPath form to SharePoint's Imaging web service to be able to upload an image to a SharePoint picture library using an InfoPath browser form or Filler form.