<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Flex Examples &#187; minimum</title>
	<atom:link href="http://blog.flexexamples.com/tag/minimum/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.flexexamples.com</link>
	<description>Just a bunch of Adobe Flex Examples</description>
	<lastBuildDate>Wed, 26 Jan 2011 18:09:51 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Setting the value on the FxHScrollBar control in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2009/03/01/setting-the-value-on-the-fxhscrollbar-control-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/03/01/setting-the-value-on-the-fxhscrollbar-control-in-flex-gumbo/#comments</comments>
		<pubDate>Mon, 02 Mar 2009 07:59:28 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FxHScrollBar]]></category>
		<category><![CDATA[FxVScrollBar]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[maximum]]></category>
		<category><![CDATA[minimum]]></category>
		<category><![CDATA[value]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/03/01/setting-the-value-on-the-fxhscrollbar-control-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the minimum, maximum, and current value on a Flex Gumbo FxHScrollBar control by setting the minimum, maximum, and value properties.</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the minimum, maximum, and current value on a Flex Gumbo FxHScrollBar control by setting the <code>minimum</code>, <code>maximum</code>, and <code>value</code> properties.</p>
<p>Full code after the jump.</p>
<p><span id="more-986"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/03/01/setting-the-value-on-the-fxhscrollbar-control-in-flex-gumbo/ --&gt;
&lt;Application name="FxHScrollBar_value_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="value:" direction="horizontal"&gt;
                &lt;FxHSlider id="slider"
                        minimum="0"
                        maximum="100"
                        value="76"
                        liveDragging="true" /&gt;
                &lt;Label text="{hScrollBar.value}" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;FxHScrollBar id="hScrollBar"
            minimum="0"
            maximum="100"
            value="{slider.value}"
            width="100" /&gt;

&lt;/Application&gt;
</pre>
<p>You can also set the <code>value</code> property using ActionScript, as seen in the following example:</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/03/01/setting-the-value-on-the-fxhscrollbar-control-in-flex-gumbo/ --&gt;
&lt;Application name="FxHScrollBar_value_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.events.SliderEvent;

            private function slider_change(evt:Event):void {
                hScrollBar.value = evt.currentTarget.value;
            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="value:" direction="horizontal"&gt;
                &lt;FxHSlider id="slider"
                        minimum="0"
                        maximum="100"
                        liveDragging="true"
                        change="slider_change(event);" /&gt;
                &lt;Label text="{hScrollBar.value}" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;FxHScrollBar id="hScrollBar"
            minimum="0"
            maximum="100"
            width="100" /&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the value on the FxHScrollBar control in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/03/01/setting-the-value-on-the-fxhscrollbar-control-in-flex-gumbo/',contentID: 'post-986',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'Gumbo,maximum,minimum,value',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/03/01/setting-the-value-on-the-fxhscrollbar-control-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting specific minimum and maximum ranges for a Flex LineChart control LinearAxis</title>
		<link>http://blog.flexexamples.com/2007/11/19/setting-specific-minimum-and-maximum-ranges-for-a-flex-linechart-control-linearaxis/</link>
		<comments>http://blog.flexexamples.com/2007/11/19/setting-specific-minimum-and-maximum-ranges-for-a-flex-linechart-control-linearaxis/#comments</comments>
		<pubDate>Tue, 20 Nov 2007 06:16:37 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[Charting]]></category>
		<category><![CDATA[LineChart]]></category>
		<category><![CDATA[interval]]></category>
		<category><![CDATA[maximum]]></category>
		<category><![CDATA[minimum]]></category>
		<category><![CDATA[minorInterval]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2007/11/19/setting-specific-minimum-and-maximum-ranges-for-a-flex-linechart-control-linearaxis/</guid>
		<description><![CDATA[<p>The following example shows how you can set a specific minimum and maximum LinearAxis range for a LineChart control in Flex.</p> <p>Full code after the jump.</p> <p></p> <p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearAxis_computedMinimum_test/main.mxml">View MXML</a></p> &#60;?xml version="1.0"?&#62; &#60;!-- http://blog.flexexamples.com/2007/11/19/setting-specific-minimum-and-maximum-ranges-for-a-flex-linechart-control-linearaxis/ --&#62; &#60;mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" verticalAlign="middle" backgroundColor="white" preinitialize="init();"&#62; &#60;mx:Script&#62; &#60;![CDATA[ import mx.charts.chartClasses.IAxis; import mx.formatters.CurrencyFormatter; private var currFormatter:CurrencyFormatter; private function init():void { [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set a specific minimum and maximum LinearAxis range for a LineChart control in Flex.</p>
<p>Full code after the jump.</p>
<p><span id="more-314"></span></p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearAxis_computedMinimum_test/main.mxml">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0"?&gt;
&lt;!-- http://blog.flexexamples.com/2007/11/19/setting-specific-minimum-and-maximum-ranges-for-a-flex-linechart-control-linearaxis/ --&gt;
&lt;mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"
        preinitialize="init();"&gt;

    &lt;mx:Script&gt;
        &lt;![CDATA[
            import mx.charts.chartClasses.IAxis;
            import mx.formatters.CurrencyFormatter;

            private var currFormatter:CurrencyFormatter;

            private function init():void {
                currFormatter = new CurrencyFormatter();
                currFormatter.precision = 2;
            }

            private function linearAxis_labelFunc(item:Object, prevValue:Object, axis:IAxis):String {
                return currFormatter.format(item);
            }

            private function lineChart_creationComplete():void {
                var linearAxisMinimum:int = Math.floor(linearAxis.computedMinimum);
                var linearAxisMaximum:int = Math.ceil(linearAxis.computedMaximum);
                linearAxis.minimum = linearAxisMinimum;
                linearAxis.maximum = linearAxisMaximum;
            }
        ]]&gt;
    &lt;/mx:Script&gt;

    &lt;mx:XMLListCollection id="dp"&gt;
        &lt;mx:source&gt;
            &lt;mx:XMLList&gt;
                &lt;quote date="8/27/2007" open="40.38" close="40.81" /&gt;
                &lt;quote date="8/24/2007" open="40.5" close="40.41" /&gt;
                &lt;quote date="8/23/2007" open="40.82" close="40.6" /&gt;
                &lt;quote date="8/22/2007" open="40.4" close="40.77" /&gt;
                &lt;quote date="8/21/2007" open="40.41" close="40.13" /&gt;
                &lt;quote date="8/20/2007" open="40.55" close="40.74" /&gt;
                &lt;quote date="8/17/2007" open="40.18" close="40.32" /&gt;
                &lt;quote date="8/16/2007" open="39.83" close="39.96" /&gt;
                &lt;quote date="8/15/2007" open="40.22" close="40.18" /&gt;
                &lt;quote date="8/14/2007" open="41.01" close="40.41" /&gt;
                &lt;quote date="8/13/2007" open="41" close="40.83" /&gt;
                &lt;quote date="8/10/2007" open="41.3" close="41.06" /&gt;
                &lt;quote date="8/9/2007" open="39.9" close="40.75" /&gt;
                &lt;quote date="8/8/2007" open="39.61" close="40.23" /&gt;
                &lt;quote date="8/7/2007" open="39.08" close="39.42" /&gt;
                &lt;quote date="8/6/2007" open="38.71" close="39.38" /&gt;
                &lt;quote date="8/3/2007" open="39.47" close="38.75" /&gt;
                &lt;quote date="8/2/2007" open="39.4" close="39.52" /&gt;
                &lt;quote date="8/1/2007" open="40.29" close="39.58" /&gt;
            &lt;/mx:XMLList&gt;
        &lt;/mx:source&gt;
    &lt;/mx:XMLListCollection&gt;

    &lt;mx:ApplicationControlBar dock="true"&gt;
        &lt;mx:Form styleName="plain"&gt;
            &lt;mx:FormItem label="minimum:"&gt;
                &lt;mx:HSlider id="minSlider"
                        minimum="28"
                        maximum="38"
                        value="38"
                        liveDragging="true"
                        snapInterval="1"
                        change="linearAxis.minimum = event.value;" /&gt;
            &lt;/mx:FormItem&gt;
            &lt;mx:FormItem label="maximum:"&gt;
                &lt;mx:HSlider id="maxSlider"
                        minimum="42"
                        maximum="52"
                        value="42"
                        liveDragging="true"
                        snapInterval="1"
                        change="linearAxis.maximum = event.value;" /&gt;
            &lt;/mx:FormItem&gt;
        &lt;/mx:Form&gt;

        &lt;mx:Spacer width="100%" /&gt;

        &lt;mx:Legend dataProvider="{lineChart}"
                direction="horizontal" /&gt;
    &lt;/mx:ApplicationControlBar&gt;

    &lt;mx:LineChart id="lineChart"
            showDataTips="true"
            dataProvider="{dp}"
            width="100%"
            height="100%"
            creationComplete="lineChart_creationComplete();"&gt;

        &lt;mx:backgroundElements&gt;
            &lt;mx:GridLines id="gridLines"
                    direction="both"
                    verticalTickAligned="false"&gt;
                &lt;mx:verticalStroke&gt;
                    &lt;mx:Stroke color="haloSilver"
                            weight="0"
                            alpha="1.0" /&gt;
                &lt;/mx:verticalStroke&gt;
                &lt;mx:horizontalStroke&gt;
                    &lt;!-- Set alpha to 0 so stroke isn't visible. --&gt;
                    &lt;mx:Stroke color="white"
                            weight="0"
                            alpha="0.0" /&gt;
                &lt;/mx:horizontalStroke&gt;
                &lt;mx:horizontalFill&gt;
                    &lt;mx:SolidColor color="haloSilver"
                            alpha="0.1" /&gt;
                &lt;/mx:horizontalFill&gt;
            &lt;/mx:GridLines&gt;
        &lt;/mx:backgroundElements&gt;

        &lt;!-- vertical axis --&gt;
        &lt;mx:verticalAxis&gt;
            &lt;mx:LinearAxis id="linearAxis"
                    baseAtZero="false"
                    title="Price (USD)"
                    minorInterval="0.10"
                    interval="0.5"
                    labelFunction="linearAxis_labelFunc" /&gt;
        &lt;/mx:verticalAxis&gt;

        &lt;!-- horizontal axis --&gt;
        &lt;mx:horizontalAxis&gt;
            &lt;mx:CategoryAxis id="ca"
                    categoryField="@date"
                    title="Date" /&gt;
        &lt;/mx:horizontalAxis&gt;

        &lt;!-- horizontal axis renderer --&gt;
        &lt;mx:horizontalAxisRenderers&gt;
            &lt;mx:AxisRenderer axis="{ca}"
                    canDropLabels="true" /&gt;
        &lt;/mx:horizontalAxisRenderers&gt;

        &lt;!-- series --&gt;
        &lt;mx:series&gt;
            &lt;mx:LineSeries yField="@open"
                    displayName="Open" /&gt;
        &lt;/mx:series&gt;
    &lt;/mx:LineChart&gt;

&lt;/mx:Application&gt;
</pre>
<p class="information"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearAxis_computedMinimum_test/bin/srcview/index.html">View source</a> is enabled in the following example.</p>
<p><iframe src="http://blog.flexexamples.com/wp-content/uploads/LinearAxis_computedMinimum_test/bin/main.html" width="100%" height="500"></iframe></p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting specific minimum and maximum ranges for a Flex LineChart control LinearAxis on FlexExamples.com',url: 'http://blog.flexexamples.com/2007/11/19/setting-specific-minimum-and-maximum-ranges-for-a-flex-linechart-control-linearaxis/',contentID: 'post-314',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'interval,maximum,minimum,minorInterval',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2007/11/19/setting-specific-minimum-and-maximum-ranges-for-a-flex-linechart-control-linearaxis/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
	</channel>
</rss>

