Questions tagged [spfile]
A class of the Microsoft.SharePoint namespace that represents a file in a SharePoint Web site that can be a Web Parts page, an item in a document library, or a file in a folder.
51 questions
1 vote
0 answers
130 views
How to move a file programmatically and preserve full version history (including users!)?
I have a document approval system that works something like this: User uploads a document to one library, fills out metadata. Approval process begins, workflows are fired to send out notification ...
3 votes
1 answer
179 views
How to check the file is used by another process?
In sharepoint from Document library i was read the file and Download the file using FileStream object. Sometime it was downloading. Sometime i will receive the following error. The process cannot ...
0 votes
1 answer
1k views
How to checkin SPCheckedOutFile
In Powershell i get all checked out file from a library with foreach($f in $lib.CheckedOutFiles){ //I tried to retrieve item with $item = $lib.GetItemById($f.ListItemID)//exception item not ...
1 vote
0 answers
54 views
Timezone issues and file size differing for spfilezilla
I've uploaded some files from a local server to the Office 365 sharepoint cloud using spfilezilla. However I notice the times are different by the same offset of a few hours. Would this be a timezone ...
1 vote
1 answer
304 views
Add SPListItem with file
I have a library, that have items and each item has additional File field. I can upload them programmicaly - firsly file is uploaded, then empty item is updated with other info. Example of filled ...
1 vote
1 answer
77 views
How can I move ONE document to another library without looping an entire collection?
Currently I'm looping through all the files in a collection, which is every single document in the library. Once I find the unique document name, I move it. I'm trying to getting away from looping ...
6 votes
2 answers
2k views
Can we unlock a ShortTerm lock via CSOM for SP2013
We are using SP2013 with OWA installed. Users often complain about a file stored in SharePiont being locked by another user not in office. Error is "The file "xxxx" is locked for exclusive use by ...
1 vote
1 answer
44 views
Changing to Fields with using SystemUpdate()
I'm trying to update some fields on SPListItem but i want to prevent Modified Date/ModifiedBy fields also don't want new version. So SystemUpdate(false) is used for my case but it can not prevent that ...