Tuesday, December 8, 2020

SystemUpdate()?

Created by, Modified by, Created and Modified.

Display Name Vs Internal Name 


  • Created by    >  Author
  • Modified by  >  Editor

SharePointPnPPowerShellOnline\Set-PnPListItem -List "EMp" -Identity "5" -Values @{"Editor" ="raghu@peakinders.org"} 


SharePointPnPPowerShellOnline\Set-PnPListItem -List "EMp"  -Identity "5" -Values @{"Modified"=$olddate}-SystemUpdate

• Modified and Modified By fields changed 

• No new version (You can pass false to the method just to enable generating a new version)

SharePoint Online: How to take SharePoint Online Backup ?

 SharePoint Online: we have two types of the Service Scope.

  • Service Backup- all the content is backed up on a regular basis in the case there is corruption 
  • Deletion Backup- users will accidentally or purposely delete content. Its avaliable for 93 days only.


We can Requesting Backups from Microsoft raise the ticket.

  • backs up content every 12 hours, and take a few days to restore, so depending on the urgency for getting the data
SharePoint Online Backup


  1. we can syncing the data one drive to SharePoint or SharePoint to One drive  Bidirectional option.
  2. Timer Job to create the backup.
  3. PowerShell to copy all the data local drive

https://techcommunity.microsoft.com/t5/sharepoint/sharepoint-online-backup-strategies-for-a-cloudy-day/m-p/225418 


SharePoint Online:How to do Move Site and subsites into another site?

  •  http://yoursite/_layouts/sitemanager.aspx", 
  • Go to site manager option
  • Select the parent site of the subsite you want to move in the left navigation pane.
  • Check the box next to the subsite you want to move in the right pane.
  • Click Actions drop-down and click Move.
  • Select Destination of the subsite selected in the next dialog
Move Site and subsites into another site


Or 

We can use the Tool SharePoint Migration Tool, ShareGate or Content Matrix trail version

Saturday, December 5, 2020

Difference between the workflows and power Automate/Power Apps?


Difference between the workflows and power Automate/Power Apps


Workflow

  • SP 2010 workflows executed runtime
  • SP 2013 workflows runs workflow manger independently 
  • It runs endlessly
  • RestAPI calls are support
  • History maintains in workflow history list
  • impersonation step to act as a different user
  • Workflow types: List workflow, site workflow and reusable workflow

Power Automate:

  • It runs for 30 days only
  • “service account” user with a Power Automate license and run these flows with that user account
  • History maintains in power automate dashboard
  • impersonation step is not available
  • Types: Single approval , sequential approval and parallel approvals


Wednesday, December 2, 2020

Display SharePoint list items using rest api

 <div>

<input type="button" id="btnSubmit" value="Get List Details" />

</div>

<div id="divResults"></div>


<script>

$(function () {

$("#btnSubmit").on("click", function () {

getListData();

});

});


function getListData() {

var fullUrl = _spPageContextInfo.webAbsoluteUrl + "/_api/web/lists/getByTitle('Projection')/items";

$.ajax({

url: fullUrl,

type: "GET",

headers: {

"accept": "application/json;odata=verbose",

"content-type": "application/json;odata=verbose",

},

success: onQuerySucceeded,

error: onQueryFailed

});

}


function onQuerySucceeded(data) {

var listItemInfo = ";

$.each(data.d.results, function (key, value) {

listItemInfo += '<b>Title:</b> ' + value.Title + ' – <b>Billable hours:</b> ' + value.BillableDays + '<br />';

});

$("#divResults").html(listItemInfo);

}

function onQueryFailed() {

alert('Error!');

}

</script>