SPDocumentLibrary docLib =
(SPDocumentLibrary)webDoc.Lists[“Library Name”];
docLib.EnableVersioning = true;
docLib.EnableMinorVersions = false;
docLib.MajorVersionLimit = 2; // set version limit also
docLib.Update();
docLib.EnableVersioning = true;
docLib.EnableMinorVersions = false;
docLib.MajorVersionLimit = 2; // set version limit also
docLib.Update();
No comments:
Post a Comment