New-WssMsoSharePointLibrary
New-WssMsoSharePointLibrary
Creates a library.
Sintaxis
Parameter Set: Default
New-WssMsoSharePointLibrary [-Name] <String> [[-Description] <String> ] [[-LibraryType] <SharePointLibraryType> {InvalidType | NoListTemplate | DocumentLibrary | PictureLibrary | WebPageLibrary} ] [[-Site] <SharePointSite> ] [[-EnableVersioning]] [[-ForceCheckout]] [ <CommonParameters>]
Descripción detallada
The New-WssMsoSharePointLibrary cmdlet creates a library. A site stores the library.
Parámetros
-Description<String>
Specifies a description of a library. The cmdlet creates the library with the description that you specify.
Alias |
ninguno |
¿Requerido? |
false |
¿Posición? |
2 |
Valor predeterminado |
ninguno |
¿Aceptar canalización? |
True (ByPropertyName) |
¿Aceptar caracteres comodín? |
false |
-EnableVersioning
Indicates that versioning is enabled for this library.
Alias |
ninguno |
¿Requerido? |
false |
¿Posición? |
5 |
Valor predeterminado |
ninguno |
¿Aceptar canalización? |
True (ByPropertyName) |
¿Aceptar caracteres comodín? |
false |
-ForceCheckout
Indicates that force checkout is enabled for this library.
Alias |
ninguno |
¿Requerido? |
false |
¿Posición? |
6 |
Valor predeterminado |
ninguno |
¿Aceptar canalización? |
True (ByPropertyName) |
¿Aceptar caracteres comodín? |
false |
-LibraryType<SharePointLibraryType>
Specifies the type of a library. The cmdlet creates the library with the type that you specify.
Alias |
ninguno |
¿Requerido? |
false |
¿Posición? |
3 |
Valor predeterminado |
ninguno |
¿Aceptar canalización? |
True (ByPropertyName) |
¿Aceptar caracteres comodín? |
false |
-Name<String>
Specifies the name of a library. The cmdlet creates the library with the name that you specify.
Alias |
ninguno |
¿Requerido? |
true |
¿Posición? |
1 |
Valor predeterminado |
ninguno |
¿Aceptar canalización? |
True (ByValue, ByPropertyName) |
¿Aceptar caracteres comodín? |
false |
-Site<SharePointSite>
Specifies a site. The cmdlet creates the library in the site that you specify. If you do not specify this parameter, the cmdlet creates the library under the default site.
Alias |
ninguno |
¿Requerido? |
false |
¿Posición? |
4 |
Valor predeterminado |
ninguno |
¿Aceptar canalización? |
True (ByPropertyName) |
¿Aceptar caracteres comodín? |
false |
<CommonParameters>
Este cmdlet admite los siguientes parámetros comunes: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer y -OutVariable. Para obtener más información, consulte about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).
Entradas
El tipo de entrada es el tipo de los objetos que se pueden canalizar al cmdlet.
System.String
Name
Type: System.String
Description: Name of the SharePoint library
Salidas
El tipo de resultado es el tipo de objetos que emite el cmdlet.
- SharePointLibrary
Ejemplos
Example 1: Create a SharePoint library
The first command uses the Get-WssMsoSharePointSite cmdlet to get a site, and saves the result in the $Site variable.
The second command creates a SharePoint Online library in the site specified in the $Site variable.
PS C:\> $Site = Get-WssMSOSharePointSite | Select-Object -First 1
PS C:\> New-WssMsoSharePointLibrary -Name "Documents" -Description "SharePoint library used to share documents." -LibraryType "DocumentLibrary" -Site $Site -EnableVersioning