0

Starting to work with the graph API (specifically the .Net SDK), and while the "Drive" object indicates whether the root is "personal", "business" or a SP library, I don't see anywhere to find the explicit capabilities of a drive or driveitem. Especially as it pertains to versioning.

How do you determine whether a drive or folder or specific driveitem allows versioning?

Darrel Miller
  • 139,164
  • 32
  • 194
  • 243
AWeber
  • 381
  • 1
  • 3
  • 14

1 Answers1

0

The DriveItem class has a Versions property to identify if there are versions of a file. That version field is nullable. I'm not sure if a null value indicates that versioning is not enabled or if there are no previous versions.

Darrel Miller
  • 139,164
  • 32
  • 194
  • 243
  • Right, Versions tells us about _existing_ versions of a file. There should be some way to determine whether versions are allowed in the first place. Probably on the Drive itself, since this doesn't appear to be something you can enable on a per driveitem basis. – AWeber Nov 13 '18 at 13:40