Click or drag to resize
VariantHelperCreateVariant Method
Creates new variant object (from product and options) without saving it.

Namespace: CMS.Ecommerce
Assembly: CMS.Ecommerce (in CMS.Ecommerce.dll) Version: 8.2.23
Syntax
C#
public static ProductVariant CreateVariant(
	int productId,
	ProductAttributeSet productAttributes
)

Parameters

productId
Type: SystemInt32
The product ID.
productAttributes
Type: CMS.EcommerceProductAttributeSet
The product options.

Return Value

Type: ProductVariant
New variant object.
See Also