Posts

Showing posts from February, 2016

Remove Duplicate Registration of Event Receiver- Powershell

# List all the Events registered $weburl = "http://SharepointWeb" $spweb = Get-SPWeb $weburl $spList = $spWeb.Lists["ListName"] $spList.EventReceivers | Select Name, Assembly, Type # Remove the Event Registration at index 0 $spList.EventReceivers[0].delete()

.WSP using Powershell Commands

Add-SPSolution -LiteralPath C:\Temp\SendEmailwithAttachment.wsp Install-SPSolution -identity "SendEmailwithAttachment.wsp" -GACDeployment Uninstall-SPSolution -identity "SendEmailwithAttachment.wsp" Remove-SPSolution -identity "SendEmailwithAttachment.wsp"

Hide/Show fields in NewForm, EditForm and DispForm.aspx in SharePoint 2010 using JQuery

Image
Custom SharePoint list has Field "Status" with the options 1) Deferred 2) Completed 3) Waiting on response from and another field is "Waiting on response from" is single line of text NewForm.aspx : <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js" type="text/javascript">   </script><script type="text/javascript"> $(document).ready(function() { var loadtext=$("select[title$='Status'] :selected").text(); if(loadtext=='Deferred') { $("td.ms-formlabel:contains('Waiting on response from')").parent().hide(); //$("input[title$='Waiting on response from']").attr('disabled', true); } $("select[title$='Status']").change(function() { var text = $("select[title$='Status'] :selected").text(); if(text!='Waiting on response from') { //$("input[title$='W...