Click or drag to resize
VariantHelperGetVariantID Method
Return variant ID based on name and page template ID

Namespace: CMS.PortalEngine
Assembly: CMS.PortalEngine.Web.UI (in CMS.PortalEngine.Web.UI.dll) Version: 13.0.131
Syntax
C#
public static int GetVariantID(
	VariantModeEnum type,
	int pageTemplateID,
	string variantName,
	Nullable<bool> documentIdIsNull = null
)

Parameters

type
Type: CMS.PortalEngineVariantModeEnum
Type of variant
pageTemplateID
Type: SystemInt32
Variant's page template ID
variantName
Type: SystemString
Variant's name
documentIdIsNull (Optional)
Type: SystemNullableBoolean
If set, adds check to SQL query whether the variant document id is null or not

Return Value

Type: Int32
See Also