SOLVED

Change the value of Built-in columns Modified and Modified by

Copper Contributor

At work we are working on a document that will be used by employees to check if they are okay during a catastrophic event. 

I made a list within sharepoint to accomplish this. 

The list has the following columns: Name (text), Status(choice), Location (Choice+multipleoptions+adding your own option), Comments (Text) and the built-in Modified and Modified by.

I showed all my work to upper management but they don't like how my name and the date when I added the name values show.

For example 

Name 

Employee name (Added by me) | Status choice | Location Choice| Comments | (Date when I added the employee name and my name) 

They want the form to be 100% clean and then things to auto populate as people start using them.

Is there anyway to clean those values from modified and modified by? only once since it is just so it looks clean and presentable for upper management. 

I really hope this makes sense, please let me know if you have any questions. 

5 Replies
best response confirmed by danbmunoz (Copper Contributor)
Solution

@danbmunoz These are SharePoint default columns which cannot be changed using SharePoint user interface.

 

But, you can update it easily using PnP PowerShell like: 

 

Set-PnPListItem -List "My List" -Identity 1 -Values @{"Editor"="email address removed for privacy reasons"} -UpdateType UpdateOverwriteVersion

 

Also, going forward whoever will be adding new list items will be shown in Created By (Author) column and the user who modifies the list item will be shown in Modified By (Editor) column automatically in the list when they will start using it.

 

Author and Editor are internal names of Created By and Modified By fields respectively. Those are required to use in the PnP PowerShell for changing values.


Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.

@ganeshsanap okay so that PS command helps cleaning the modified by, column. How can I accomplish the same with Modified ( date and time )

thank you for your reply 

@danbmunoz Try using this: 

 

Set-PnPListItem -List "My List" -Identity 1 -Values @{"Editor"="<email address>"; "Modified"="2023-05-26T10:44:00"} -UpdateType UpdateOverwriteVersion

 


Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.

I was wondering if there is a way to "clean" it. The PS cmdlets worked but I want to clean the date and time and make it look like: " - " or something like that so it looks cleaner when demoing

@danbmunoz Why don't you hide those columns from the list view if you don't want to show them while demo? 

 

Follow this documentation: Show or hide columns in a list or library 


Please consider giving a Like if my post helped you in any way.

1 best response

Accepted Solutions
best response confirmed by danbmunoz (Copper Contributor)
Solution

@danbmunoz These are SharePoint default columns which cannot be changed using SharePoint user interface.

 

But, you can update it easily using PnP PowerShell like: 

 

Set-PnPListItem -List "My List" -Identity 1 -Values @{"Editor"="email address removed for privacy reasons"} -UpdateType UpdateOverwriteVersion

 

Also, going forward whoever will be adding new list items will be shown in Created By (Author) column and the user who modifies the list item will be shown in Modified By (Editor) column automatically in the list when they will start using it.

 

Author and Editor are internal names of Created By and Modified By fields respectively. Those are required to use in the PnP PowerShell for changing values.


Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.

View solution in original post