This project has moved. For the latest updates, please go here.

Add-CrmContent

Synopsis

Add new record

Syntax

Add-CrmContent [-Record] <Entity> [<CommonParameters>]

Add-CrmContent [-Entity] <String> [[-Id] <Guid>] [-Attributes] <Hashtable> [<CommonParameters>]

Description

Adds a new record to an entity

Parameters

-Record <Entity>

Entity object to add

Required? True
Position? 1
Default value  
Accept pipeline input? false
Accept wildcard characters? False

-Entity <String>

Logicalname of the entity to add record to

Required? True
Position? 1
Default value  
Accept pipeline input? false
Accept wildcard characters? False

-Id <Guid>

Id for the new record to add

Required? False
Position? 2
Default value  
Accept pipeline input? false
Accept wildcard characters? False

-Attributes <Hashtable>

Attributes and values to add
Example: @{ 'firstname' = 'Arjan'; 'lastname' = 'Meskers' }

Required? True
Position? 3
Default value  
Accept pipeline input? false
Accept wildcard characters? False

<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, InformationAction, InformationVariable,
WarningAction, WarningVariable, OutBuffer, PipelineVariable and OutVariable.
For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).

Inputs

Outputs

Microsoft.Xrm.Sdk.Entity

Notes

Examples

Add record

PS C:\> Add-CrmContent -Entity contact -Attributes @{ 'firstname' = 'Arjan'; 'lastname' = 'Meskers' }

Add a new record to Contact

Related links

Entity Class https://msdn.microsoft.com/en-us/library/microsoft.xrm.sdk.entity.aspx

Last edited Mar 11 at 7:02 PM by amsoftware, version 2