# Wijmo_Olap.Pivotfield

## Content

<div class="content__tsd">
						<div style="display:flex;justify-content:space-between;align-items:center">
							<h1>
								PivotField Class
							</h1>
						</div>
						<section class="tsd-comment">
							<div class="tsd-comment">
								<div class="lead">
									<p>Represents a property of the items in the wijmo.olap data source.</p>
								</div>
							</div>
						</section>
						<section class="tsd-type-parameters">
							<h3>Type parameters</h3>
							<ul class="tsd-type-parameters">
								<li>
									<h4>T</h4>
								</li>
							</ul>
						</section>
						<section class="tsd-hierarchy">
							<h3>Heirarchy</h3>
							<ul class="tsd-hierarchy">
								<li>
									<span class="target">PivotField</span>
									<ul class="tsd-hierarchy">
										<li>
											<a href="wijmo_olap.cubepivotfield.html" class="tsd-signature-type">CubePivotField</a>
										</li>
									</ul>
								</li>
							</ul>
						</section>
						<section class="tsd-index-group">
							<section class="tsd-index-panel">
								<div class="tsd-index-content">
									<section class="tsd-index-section ">
										<div class="title">
											<div class="gc_api_tree-item_icon_img_wrapper">
												<div class="gc_api_tree-item_icon_img" data-expand="true">
												</div>
											</div>
											<h3>
												Constructors
											</h3>
										</div>
										<ul class="tsd-index-list">
											<li class="tsd-kind-constructor tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#constructor" class="tsd-kind-icon">constructor</a></li>
										</ul>
									</section>
									<section class="tsd-index-section ">
										<div class="title">
											<div class="gc_api_tree-item_icon_img_wrapper">
												<div class="gc_api_tree-item_icon_img" data-expand="true">
												</div>
											</div>
											<h3>
												Properties
											</h3>
										</div>
										<ul class="tsd-index-list">
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#aggregate" class="tsd-kind-icon">aggregate</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#align" class="tsd-kind-icon">align</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#binding" class="tsd-kind-icon">binding</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#collectionview" class="tsd-kind-icon">collection<wbr>View</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#datatype" class="tsd-kind-icon">data<wbr>Type</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#descending" class="tsd-kind-icon">descending</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#engine" class="tsd-kind-icon">engine</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#filter" class="tsd-kind-icon">filter</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#format" class="tsd-kind-icon">format</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#getaggregatevalue" class="tsd-kind-icon">get<wbr>Aggregate<wbr>Value</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#getvalue" class="tsd-kind-icon">get<wbr>Value</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#header" class="tsd-kind-icon">header</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#isactive" class="tsd-kind-icon">is<wbr>Active</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#iscontenthtml" class="tsd-kind-icon">is<wbr>Content<wbr>Html</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#ismeasure" class="tsd-kind-icon">is<wbr>Measure</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#key" class="tsd-kind-icon">key</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#parentfield" class="tsd-kind-icon">parent<wbr>Field</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#showas" class="tsd-kind-icon">show<wbr>As</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#sortcomparer" class="tsd-kind-icon">sort<wbr>Comparer</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#subfields" class="tsd-kind-icon">sub<wbr>Fields</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#visible" class="tsd-kind-icon">visible</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#weightfield" class="tsd-kind-icon">weight<wbr>Field</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#width" class="tsd-kind-icon">width</a></li>
											<li class="tsd-kind-property tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#wordwrap" class="tsd-kind-icon">word<wbr>Wrap</a></li>
										</ul>
									</section>
									<section class="tsd-index-section ">
										<div class="title">
											<div class="gc_api_tree-item_icon_img_wrapper">
												<div class="gc_api_tree-item_icon_img" data-expand="true">
												</div>
											</div>
											<h3>
												Methods
											</h3>
										</div>
										<ul class="tsd-index-list">
											<li class="tsd-kind-method tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#onpropertychanged" class="tsd-kind-icon">on<wbr>Property<wbr>Changed</a></li>
										</ul>
									</section>
									<section class="tsd-index-section ">
										<div class="title">
											<div class="gc_api_tree-item_icon_img_wrapper">
												<div class="gc_api_tree-item_icon_img" data-expand="true">
												</div>
											</div>
											<h3>
												Events
											</h3>
										</div>
										<ul class="tsd-index-list">
											<li class="tsd-kind-event tsd-parent-kind-class"><a href="wijmo_olap.pivotfield.html#propertychanged" class="tsd-kind-icon">property<wbr>Changed</a></li>
										</ul>
									</section>
								</div>
							</section>
						</section>
						<section class="tsd-panel-group tsd-member-group ">
							<h2>Constructors</h2>
							<section class="tsd-panel tsd-member tsd-kind-constructor tsd-parent-kind-class">
								<a name="constructor" class="tsd-anchor"></a>
								<h3>constructor</h3>
								<ul class="tsd-signatures tsd-kind-constructor tsd-parent-kind-class">
									<li class="tsd-signature tsd-kind-icon">new <wbr>Pivot<wbr>Field<span class="tsd-signature-symbol">(</span>engine<span class="tsd-signature-symbol">: </span><a href="wijmo_olap.pivotengine.html" class="tsd-signature-type">PivotEngine</a>, binding<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span>, header<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">string</span>, options<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="wijmo_olap.pivotfield.html" class="tsd-signature-type">PivotField</a></li>
								</ul>
								<ul class="tsd-descriptions">
									<li class="tsd-description">
										<aside class="tsd-sources">
										</aside>
										<div class="tsd-comment">
											<div class="lead">
												<p>Initializes a new instance of the <a href="wijmo_olap.pivotfield.html">PivotField</a> class.</p>
											</div>
										</div>
										<h4 class="tsd-parameters-title">Parameters</h4>
										<ul class="tsd-parameters">
											<li>
												<h5>engine: <a href="wijmo_olap.pivotengine.html" class="tsd-signature-type">PivotEngine</a></h5>
												<div class="tsd-comment">
													<div class="lead">
														<p><a href="wijmo_olap.pivotengine.html">PivotEngine</a> that owns this field.</p>
													</div>
												</div>
											</li>
											<li>
												<h5>binding: <span class="tsd-signature-type">string</span></h5>
												<div class="tsd-comment">
													<div class="lead">
														<p>Property that this field is bound to.</p>
													</div>
												</div>
											</li>
											<li>
												<h5><span class="tsd-flag ts-flagOptional">Optional</span> header: <span class="tsd-signature-type">string</span></h5>
												<div class="tsd-comment">
													<div class="lead">
														<p>Header shown to identify this field (defaults to the binding).</p>
													</div>
												</div>
											</li>
											<li>
												<h5><span class="tsd-flag ts-flagOptional">Optional</span> options: <span class="tsd-signature-type">any</span></h5>
												<div class="tsd-comment">
													<div class="lead">
														<p>JavaScript object containing initialization data for the field.</p>
													</div>
												</div>
											</li>
										</ul>
										<h4 class="tsd-returns-title">Returns <a href="wijmo_olap.pivotfield.html" class="tsd-signature-type">PivotField</a></h4>
									</li>
								</ul>
							</section>
						</section>
						<section class="tsd-panel-group tsd-member-group ">
							<h2>Properties</h2>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="aggregate" class="tsd-anchor"></a>
								<h3>aggregate</h3>
								<div class="tsd-signature tsd-kind-icon">aggregate<span class="tsd-signature-symbol">:</span> <a href="../enums/wijmo.aggregate.html" class="tsd-signature-type">Aggregate</a></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets how the field should be summarized.</p>
									</div>
									<p>The default value for this property is <strong>Aggregate.Sum</strong>
										for numeric fields, and <strong>Aggregate.Count</strong> for other
									field types.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="align" class="tsd-anchor"></a>
								<h3>align</h3>
								<div class="tsd-signature tsd-kind-icon">align<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets the horizontal alignment of this field's cells.</p>
									</div>
									<p>The default value for this property is null, which causes the grid to select
										the alignment automatically based on the fields's <a href="wijmo_olap.pivotfield.html#datatype">dataType</a> (numbers are
									right-aligned, Boolean values are centered, and other types are left-aligned).</p>
									<p>If you want to override the default alignment, set this property
									to 'left', 'right', 'center', or 'justify'.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="binding" class="tsd-anchor"></a>
								<h3>binding</h3>
								<div class="tsd-signature tsd-kind-icon">binding<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets the name of the property the field is bound to.</p>
									</div>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="collectionview" class="tsd-anchor"></a>
								<h3>collectionView</h3>
								<div class="tsd-signature tsd-kind-icon">collection<wbr>View<span class="tsd-signature-symbol">:</span> <a href="../interfaces/wijmo.icollectionview.html" class="tsd-signature-type">ICollectionView</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">T</span><span class="tsd-signature-symbol">&gt;</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets the <a href="../interfaces/wijmo.icollectionview.html">ICollectionView</a> bound to this field.</p>
									</div>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="datatype" class="tsd-anchor"></a>
								<h3>dataType</h3>
								<div class="tsd-signature tsd-kind-icon">data<wbr>Type<span class="tsd-signature-symbol">:</span> <a href="../enums/wijmo.datatype.html" class="tsd-signature-type">DataType</a></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets the data type of the field.</p>
									</div>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="descending" class="tsd-anchor"></a>
								<h3>descending</h3>
								<div class="tsd-signature tsd-kind-icon">descending<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a value that determines whether keys should be sorted
										in descending order for this field.</p>
									</div>
									<p>The default value for this property is <strong>false</strong>.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="engine" class="tsd-anchor"></a>
								<h3>engine</h3>
								<div class="tsd-signature tsd-kind-icon">engine<span class="tsd-signature-symbol">:</span> <a href="wijmo_olap.pivotengine.html" class="tsd-signature-type">PivotEngine</a></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets a reference to the <a href="wijmo_olap.pivotengine.html">PivotEngine</a> that owns this <a href="wijmo_olap.pivotfield.html">PivotField</a>.</p>
									</div>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="filter" class="tsd-anchor"></a>
								<h3>filter</h3>
								<div class="tsd-signature tsd-kind-icon">filter<span class="tsd-signature-symbol">:</span> <a href="wijmo_olap.pivotfilter.html" class="tsd-signature-type">PivotFilter</a></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets a reference to the <a href="wijmo_olap.pivotfilter.html">PivotFilter</a> used to filter values for this field.</p>
									</div>
									<p>For measure fields in cube data sources, the filter is applied to aggregated
										cell values. For measure fields in non-cube data sources, the filter is
									applied to the raw data.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="format" class="tsd-anchor"></a>
								<h3>format</h3>
								<div class="tsd-signature tsd-kind-icon">format<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets the format to use when displaying field values.</p>
									</div>
									<p>The default value for this property is
										<strong>"d"</strong> for date fields, <strong>"n0"</strong> for numeric fields,
									and the empty string for other field types.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="getaggregatevalue" class="tsd-anchor"></a>
								<h3>getAggregateValue</h3>
								<div class="tsd-signature tsd-kind-icon">get<wbr>Aggregate<wbr>Value<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Function</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a function to be used for retrieving the field's
										<strong>aggregate</strong> value for a given summary object.</p>
									</div>
									<p>The default value for this property is <strong>null</strong>, causing the engine to
										use the field's <a href="wijmo_olap.pivotfield.html#aggregate">aggregate</a> and <a href="wijmo_olap.pivotfield.html#showas">showAs</a> properties to
									calculate the aggregate.</p>
									<p>If specified, the function should take a single parameter that
										represents the summary object generated by the engine and should return
									the aggregate value for the item.</p>
									<p>Notice the difference between the <a href="wijmo_olap.pivotfield.html#getvalue">getValue</a> property
										(a function that takes a raw data item and returns a raw value), and
										the <a href="wijmo_olap.pivotfield.html#getaggregatevalue">getAggregateValue</a> (a function that takes a summary object
									and returns an aggregate value):</p>
									<pre><code class="language-typescript">fields: [
    {
        header: <span class="hljs-string">'Conversion (per summary row)'</span>,
        dataType: <span class="hljs-string">'Number'</span>,
        format: <span class="hljs-string">'p0'</span>,

        <span class="hljs-comment">// getAggregateValue computes an aggregate from a summary row (Downloads, Sales)</span>
        <span class="hljs-comment">// **NOTE**: for this formula to work, the "Downloads" and "Sales" fields must be</span>
        <span class="hljs-comment">// present in the PivotEngine's valueFields array.</span>
        getAggregateValue: <span class="hljs-function"><span class="hljs-params">row</span> =&gt;</span> row.Downloads ? row.Sales / row.Downloads : <span class="hljs-number">0</span>
    },
    {
        header: <span class="hljs-string">'Conversion (per raw data item)'</span>,
        dataType: <span class="hljs-string">'Number'</span>,
        aggregate: <span class="hljs-string">'Avg'</span>,
        format: <span class="hljs-string">'p0'</span>,

        <span class="hljs-comment">// getValue computes a raw value from a data item (downloads, sales)</span>
        getValue: <span class="hljs-function"><span class="hljs-params">item</span> =&gt;</span> item.downloads ? item.sales / item.downloads : <span class="hljs-number">0</span>
},</code></pre>
									<p><a href="/wijmo/demos/OLAP/PivotPanel/Fields/Customize/FieldSettingsDialog/Calculated" target="_blank">Example</a></p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="getvalue" class="tsd-anchor"></a>
								<h3>getValue</h3>
								<div class="tsd-signature tsd-kind-icon">get<wbr>Value<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Function</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a function to be used for retrieving the field value
										for a given data item.</p>
									</div>
									<p>This property is set to null by default, causing the engine to
									use the field's <a href="wijmo_olap.pivotfield.html#binding">binding</a> property to retrieve the value.</p>
									<p>If specified, the function should take a single parameter that
										represents the data item being evaluated and should return
									the calculated value for the item.</p>
									<p>Notice the difference between the <a href="wijmo_olap.pivotfield.html#getvalue">getValue</a> property
										(a function that takes a raw data item and returns a raw value), and
										the <a href="wijmo_olap.pivotfield.html#getaggregatevalue">getAggregateValue</a> (a function that takes a summary object
									and returns an aggregate value):</p>
									<pre><code class="language-typescript">fields: [
    {
        header: <span class="hljs-string">'Conversion (per summary row)'</span>,
        dataType: <span class="hljs-string">'Number'</span>,
        format: <span class="hljs-string">'p0'</span>,

        <span class="hljs-comment">// getAggregateValue computes an aggregate from a summary row (Downloads, Sales)</span>
        getAggregateValue: <span class="hljs-function"><span class="hljs-params">row</span> =&gt;</span> row.Downloads ? row.Sales / row.Downloads : <span class="hljs-number">0</span>
    },
    {
        header: <span class="hljs-string">'Conversion (per raw data item)'</span>,
        dataType: <span class="hljs-string">'Number'</span>,
        aggregate: <span class="hljs-string">'Avg'</span>,
        format: <span class="hljs-string">'p0'</span>,

        <span class="hljs-comment">// getValue computes a raw value from a data item (downloads, sales)</span>
        getValue: <span class="hljs-function"><span class="hljs-params">item</span> =&gt;</span> item.downloads ? item.sales / item.downloads : <span class="hljs-number">0</span>
},</code></pre>
									<p><a href="/wijmo/demos/OLAP/PivotPanel/Fields/Customize/FieldSettingsDialog/Calculated" target="_blank">Example</a></p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="header" class="tsd-anchor"></a>
								<h3>header</h3>
								<div class="tsd-signature tsd-kind-icon">header<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a string used to represent this field in the user
										interface.</p>
									</div>
									<p>The default value for this property is a capitalized version of the
									<a href="wijmo_olap.pivotfield.html#binding">binding</a> value.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="isactive" class="tsd-anchor"></a>
								<h3>isActive</h3>
								<div class="tsd-signature tsd-kind-icon">is<wbr>Active<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a value that determines whether this field is
										currently being used in the view.</p>
									</div>
									<p>Setting this property to true causes the field to be added to the
										view's <a href="wijmo_olap.pivotengine.html#rowfields">PivotEngine.rowFields</a> or <a href="wijmo_olap.pivotengine.html#valuefields">PivotEngine.valueFields</a>,
									depending on the field's data type.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="iscontenthtml" class="tsd-anchor"></a>
								<h3>isContentHtml</h3>
								<div class="tsd-signature tsd-kind-icon">is<wbr>Content<wbr>Html<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a value indicating whether items in this field
										contain HTML content rather than plain text.</p>
									</div>
									<p>The default value for this property is <strong>false</strong>.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="ismeasure" class="tsd-anchor"></a>
								<h3>isMeasure</h3>
								<div class="tsd-signature tsd-kind-icon">is<wbr>Measure<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets a value that indicates whether the field is a measure or
										a dimension.</p>
									</div>
									<p>Measures are also known as 'facts'. They are typically numeric
										values that can be aggregated into summary statistics that convey
									information about the field.</p>
									<p>Dimensions are typically strings, dates, or boolean values that
									can be used to divide measures into categories.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="key" class="tsd-anchor"></a>
								<h3>key</h3>
								<div class="tsd-signature tsd-kind-icon">key<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets the key for this <a href="wijmo_olap.pivotfield.html">PivotField</a>.</p>
									</div>
									<p>For regular fields, the key is the field's <a href="wijmo_olap.pivotfield.html#header">header</a>;
										for <a href="wijmo_olap.cubepivotfield.html">CubePivotField</a> instances, the key is the
									field's <a href="wijmo_olap.pivotfield.html#binding">binding</a>.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="parentfield" class="tsd-anchor"></a>
								<h3>parentField</h3>
								<div class="tsd-signature tsd-kind-icon">parent<wbr>Field<span class="tsd-signature-symbol">:</span> <a href="wijmo_olap.pivotfield.html" class="tsd-signature-type">PivotField</a></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets this field's parent field.</p>
									</div>
									<p>When you drag the same field into the Values list multiple
										times, copies of the field are created so you can use the
										same binding with different parameters. The copies keep a
									reference to their parent fields.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="showas" class="tsd-anchor"></a>
								<h3>showAs</h3>
								<div class="tsd-signature tsd-kind-icon">show<wbr>As<span class="tsd-signature-symbol">:</span> <a href="../enums/wijmo_olap.showas.html" class="tsd-signature-type">ShowAs</a></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a value that specifies how to display the aggregate
										value.</p>
									</div>
									<p>Options for this property are defined by the <a href="../enums/wijmo_olap.showas.html">ShowAs</a> enumeration
										and include differences between the value and the one in the previous
										row or column, percentages over the row, column, or grand total, and
									running totals.</p>
									<p>This property is similar to the
										<a href="https://support.microsoft.com/en-us/office/show-different-calculations-in-pivottable-value-fields-014d2777-baaf-480b-a32b-98431f48bfec" target="_blank">Show Values As</a>
									feature in Excel.</p>
									<p>The default value for this property is <strong>ShowAs.NoCalculation</strong>.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="sortcomparer" class="tsd-anchor"></a>
								<h3>sortComparer</h3>
								<div class="tsd-signature tsd-kind-icon">sort<wbr>Comparer<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Function</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a function used to compare values when sorting.</p>
									</div>
									<p>This <a href="wijmo_olap.pivotfield.html#sortcomparer">sortComparer</a> property is effective for the fields specified
									in the <a href="wijmo_olap.pivotengine.html#columnfields">PivotEngine.columnFields</a> and <a href="wijmo_olap.pivotengine.html#columnfields">PivotEngine.columnFields</a> properties only.</p>
									<p>If provided, the sort comparer function should take as parameters
										two values of any type, and should return -1, 0, or +1 to indicate
										whether the first value is smaller than, equal to, or greater than
										the second. If the sort comparer returns null, the standard built-in
									comparer is used.</p>
									<p>This <a href="wijmo_olap.pivotfield.html#sortcomparer">sortComparer</a> property allows you to use custom comparison
										algorithms that in some cases result in sorting sequences that are
									more consistent with user's expectations than plain string comparisons.</p>
									<p>The example below shows a typical use for the <a href="wijmo_olap.pivotfield.html#sortcomparer">sortComparer</a> property:</p>
									<pre>// define list of products
app.products = 'Wijmo,Aoba,Olap,Xuni'.split(',');

// sort products by position in the 'app.products' array
ng.viewDefinitionChanged.addHandler(function () {
  var fld = ng.fields.getField('Product');
  if (fld) {
    fld.sortComparer = function (val1, val2) {
      return app.products.indexOf(val1) - app.products.indexOf(val2);
    }
  }
});</pre>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="subfields" class="tsd-anchor"></a>
								<h3>subFields</h3>
								<div class="tsd-signature tsd-kind-icon">sub<wbr>Fields<span class="tsd-signature-symbol">:</span> <a href="wijmo_olap.pivotfield.html" class="tsd-signature-type">PivotField</a><span class="tsd-signature-symbol">[]</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets this field's child fields.</p>
									</div>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="visible" class="tsd-anchor"></a>
								<h3>visible</h3>
								<div class="tsd-signature tsd-kind-icon">visible<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a value indicating whether this field should be
										displayed in instances of the <a href="wijmo_olap.pivotpanel.html">PivotPanel</a> control.</p>
									</div>
									<p>The default value for this property is <strong>true</strong>.</p>
									<p>Setting this property to false hides the field any <a href="wijmo_olap.pivotpanel.html">PivotPanel</a>
										controls, preventing users from adding, removing, or changing the
									the field position in the engine's view definition.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="weightfield" class="tsd-anchor"></a>
								<h3>weightField</h3>
								<div class="tsd-signature tsd-kind-icon">weight<wbr>Field<span class="tsd-signature-symbol">:</span> <a href="wijmo_olap.pivotfield.html" class="tsd-signature-type">PivotField</a></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets the <a href="wijmo_olap.pivotfield.html">PivotField</a> used as a weight for calculating
										aggregates on this field.</p>
									</div>
									<p>If this property is set to null, all values are assumed to have weight one.</p>
									<p>This property allows you to calculate weighted averages and totals.
										For example, if the data contains a 'Quantity' field and a 'Price' field,
										you could use the 'Price' field as a value field and the 'Quantity' field as
									a weight. The output would contain a weighted average of the data.</p>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="width" class="tsd-anchor"></a>
								<h3>width</h3>
								<div class="tsd-signature tsd-kind-icon">width<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets the preferred width to be used for showing this
										field in user interface controls such as the <a href="wijmo_olap.pivotgrid.html">PivotGrid</a>.</p>
									</div>
								</div>
							</section>
							<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
								<a name="wordwrap" class="tsd-anchor"></a>
								<h3>wordWrap</h3>
								<div class="tsd-signature tsd-kind-icon">word<wbr>Wrap<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Gets or sets a value that indicates whether the content of this
										field should be allowed to wrap within cells.</p>
									</div>
									<p>The default value for this property is <strong>false</strong>.</p>
								</div>
							</section>
						</section>
						<section class="tsd-panel-group tsd-member-group ">
							<h2>Methods</h2>
							<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
								<a name="onpropertychanged" class="tsd-anchor"></a>
								<h3>onPropertyChanged</h3>
								<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
									<li class="tsd-signature tsd-kind-icon">on<wbr>Property<wbr>Changed<span class="tsd-signature-symbol">(</span>e<span class="tsd-signature-symbol">: </span><a href="wijmo.propertychangedeventargs.html" class="tsd-signature-type">PropertyChangedEventArgs</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
								</ul>
								<ul class="tsd-descriptions">
									<li class="tsd-description">
										<aside class="tsd-sources">
										</aside>
										<div class="tsd-comment">
											<div class="lead">
												<p>Raises the <a href="wijmo_olap.pivotfield.html#propertychanged">propertyChanged</a> event.</p>
											</div>
										</div>
										<h4 class="tsd-parameters-title">Parameters</h4>
										<ul class="tsd-parameters">
											<li>
												<h5>e: <a href="wijmo.propertychangedeventargs.html" class="tsd-signature-type">PropertyChangedEventArgs</a></h5>
												<div class="tsd-comment">
													<p><a href="wijmo.propertychangedeventargs.html">PropertyChangedEventArgs</a> that contains the property
													name, old, and new values.</p>
												</div>
											</li>
										</ul>
										<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
									</li>
								</ul>
							</section>
						</section>
						<section class="tsd-panel-group tsd-member-group ">
							<h2>Events</h2>
							<section class="tsd-panel tsd-member tsd-kind-event tsd-parent-kind-class">
								<a name="propertychanged" class="tsd-anchor"></a>
								<h3>propertyChanged</h3>
								<div class="tsd-signature tsd-kind-icon">property<wbr>Changed<span class="tsd-signature-symbol">:</span> <a href="wijmo.event.html" class="tsd-signature-type">Event</a><span class="tsd-signature-symbol">&lt;</span><a href="wijmo_olap.pivotfield.html" class="tsd-signature-type">PivotField</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">, </span><a href="wijmo.propertychangedeventargs.html" class="tsd-signature-type">PropertyChangedEventArgs</a><span class="tsd-signature-symbol">&gt;</span></div>
								<aside class="tsd-sources">
								</aside>
								<div class="tsd-comment">
									<div class="lead">
										<p>Occurs when the value of a property in this <a href="../enums/wijmo_input.dateselectionmode.html#range">Range</a> changes.</p>
									</div>
								</div>
							</section>
						</section>
					</div>