<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title><![CDATA[Curl Global Community - Try 3: Displaying Data in a Grid]]></title>
		<link>https://communities.curl.com/</link>
		<description><![CDATA[Curl Global Community - https://communities.curl.com]]></description>
		<pubDate>Wed, 29 Apr 2026 07:20:20 +0000</pubDate>
		<generator>MyBB</generator>
		<item>
			<title><![CDATA[Page 8: Extra Practice]]></title>
			<link>https://communities.curl.com/showthread.php?tid=62</link>
			<pubDate>Thu, 16 Jun 2011 07:39:21 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=62</guid>
			<description><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Extra Practice</span></span></span><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Practice Problem 1: Application</span></span></span><br />
<br />
In the "Application" sample, add a button whose function is to delete a selected line.<br />
<br />
Hint: To delete a selected line, use <span style="font-family: Courier;" class="mycode_font">{RecordGrid.delete-selection}</span>.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Solution</span></span></span><br />
<br />
Solution Program: <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\04_exercise1\start.curl</span> <br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet =<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField score, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField city, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField tel, domain = String}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Matt, age = 33, score = 88, city = Cambridge, tel = 555-1567},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Sarah, age = 27, score = 79, city = Seattle, tel = 555-5692},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Jacob, age = 26, score = 90, city = Chicago, tel = 555-7259},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Miles, age = 23, score = 98, city = Miami, tel = 555-2644},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Anna, age = 27, score = 81, city = San Diego, tel = 555-9968},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Paul, age = 28, score = 86, city = Denver, tel = 555-6389},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Diana, age = 25, score = 85, city = Atlanta, tel = 555-4712}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;let rg:RecordGrid = {RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-source = data,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;height = 3cm,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width = 10cm<br />
&nbsp;&nbs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;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;{rg.set-frozen-region 0, 1}<br />
&nbsp;&nbsp;&nbsp;&nbsp;{VBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;rg,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{HBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;sort-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;filter-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;reverse-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;delete-button<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<img src="wiki/easy-ide-book/try3/images/figure_3_14.png" /><br />
]]></description>
			<content:encoded><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Extra Practice</span></span></span><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Practice Problem 1: Application</span></span></span><br />
<br />
In the "Application" sample, add a button whose function is to delete a selected line.<br />
<br />
Hint: To delete a selected line, use <span style="font-family: Courier;" class="mycode_font">{RecordGrid.delete-selection}</span>.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Solution</span></span></span><br />
<br />
Solution Program: <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\04_exercise1\start.curl</span> <br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet =<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField score, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField city, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField tel, domain = String}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Matt, age = 33, score = 88, city = Cambridge, tel = 555-1567},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Sarah, age = 27, score = 79, city = Seattle, tel = 555-5692},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Jacob, age = 26, score = 90, city = Chicago, tel = 555-7259},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Miles, age = 23, score = 98, city = Miami, tel = 555-2644},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Anna, age = 27, score = 81, city = San Diego, tel = 555-9968},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Paul, age = 28, score = 86, city = Denver, tel = 555-6389},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Diana, age = 25, score = 85, city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&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;{rg.set-frozen-region 0, 1}<br />
&nbsp;&nbsp;&nbsp;&nbsp;{VBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;rg,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{HBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;sort-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;filter-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;reverse-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;delete-button<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<img src="wiki/easy-ide-book/try3/images/figure_3_14.png" /><br />
]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Page 7: Summary]]></title>
			<link>https://communities.curl.com/showthread.php?tid=61</link>
			<pubDate>Thu, 16 Jun 2011 07:37:08 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=61</guid>
			<description><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">TRY 3 Summary</span></span></span><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the data to be displayed with RecordSet</span></span></span><br />
<br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Data creation</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField field name 1, [option 1 = value, …] } ,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Describe field value <br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField field name x, [option x = value, …] } ,<br />
&nbsp;&nbsp;&nbsp;&nbsp;},<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordData field name 1 = data, …}, <br />
&nbsp;&nbsp;&nbsp;&nbsp;|| Describe record value <br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordData field name 1 = data, …}, <br />
}</code></div></div><br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Display the data using a Grid with RecordGrid</span></span></span><br />
<br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Grid display</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;record-source = RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;|| ,<br />
&nbsp;&nbsp;&nbsp;&nbsp;|| Option = value<br />
}</code></div></div><br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Options for modifying RecordGrid Functionality</span></span></span><br />
<br />
<img src="attachment.php?aid=103" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Options for modifying RecordGrid appearance</span></span></span><br />
<br />
<img src="attachment.php?aid=104" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Sorting and Filtering</span></span></span><br />
<br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Data sorting</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set RecordGrid-name.sort = field name</code></div></div><br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Data filtering</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set RecordGrid-name.filter = {RecordData field name = value}</code></div></div><br />
Note: By using <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSort</span></span> and <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFilter</span></span>, you can specify more complex sorting and filtering.<br />
<br />
<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=103" target="_blank" title="">3-5.PNG</a> (Size: 13.32 KB / Downloads: 1377)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=104" target="_blank" title="">3-6.PNG</a> (Size: 14.11 KB / Downloads: 1463)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">TRY 3 Summary</span></span></span><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the data to be displayed with RecordSet</span></span></span><br />
<br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Data creation</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField field name 1, [option 1 = value, …] } ,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Describe field value <br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField field name x, [option x = value, …] } ,<br />
&nbsp;&nbsp;&nbsp;&nbsp;},<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordData field name 1 = data, …}, <br />
&nbsp;&nbsp;&nbsp;&nbsp;|| Describe record value <br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordData field name 1 = data, …}, <br />
}</code></div></div><br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Display the data using a Grid with RecordGrid</span></span></span><br />
<br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Grid display</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;record-source = RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;|| ,<br />
&nbsp;&nbsp;&nbsp;&nbsp;|| Option = value<br />
}</code></div></div><br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Options for modifying RecordGrid Functionality</span></span></span><br />
<br />
<img src="attachment.php?aid=103" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Options for modifying RecordGrid appearance</span></span></span><br />
<br />
<img src="attachment.php?aid=104" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Sorting and Filtering</span></span></span><br />
<br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Data sorting</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set RecordGrid-name.sort = field name</code></div></div><br />
<span style="font-style: italic;" class="mycode_i"><span style="font-weight: bold;" class="mycode_b">Data filtering</span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set RecordGrid-name.filter = {RecordData field name = value}</code></div></div><br />
Note: By using <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSort</span></span> and <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFilter</span></span>, you can specify more complex sorting and filtering.<br />
<br />
<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=103" target="_blank" title="">3-5.PNG</a> (Size: 13.32 KB / Downloads: 1377)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=104" target="_blank" title="">3-6.PNG</a> (Size: 14.11 KB / Downloads: 1463)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Page 6: Structure of a Program that Sorts and Filters the Data]]></title>
			<link>https://communities.curl.com/showthread.php?tid=60</link>
			<pubDate>Thu, 16 Jun 2011 07:32:17 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=60</guid>
			<description><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Structure of a Program that Sorts and Filters the Data</span></span></span><br />
<br />
The <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> data can be sorted and filtered.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_12.png" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">1. Sorting data: sort</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set rg.sort = score DESC</code></div></div><br />
We can use sort to sort the data displayed by <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span>. To do so, we specify the names of the fields to be sorted as character strings. As in this example, when we want to sort the data into descending order, we add DESC after each field name. We can specify multiple fields by delimiting their names with a comma (,).<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set rg.sort = score DESC, age DESC</code></div></div><br />
By using RecordSort, we can specify more complex types of sorting.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">2. Filtering data: filter</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set rg.filter = {RecordData city = Miami}</code></div></div><br />
To filter the data to be displayed, we use the filter field. To specify the fields and data to be filtered, we use <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span>. Using <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFilter</span></span>, we can specify relatively complex filtering. If we specify null, then no filtering is performed.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">3. Fixing the display region: set-frozen-region</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{rg.set-frozen-region 0,1}</code></div></div><br />
Using set-frozen-region, we can fix the position of the <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> window frame. This prevents the scrolling of the specified lines and columns. There are several other APIs for managing fixed lines and columns. These are described in the Curl API documentation.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">4. Displaying the layout: VBox</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{VBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;rg,<br />
&nbsp;&nbsp;&nbsp;&nbsp;{HBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;sort-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;filter-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;reverse-button<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
As explained above, the final expression specified in the value block is displayed on the screen. In the current example, this <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">VBox</span></span> is the final expression. Therefore, the screen layout will appear as shown in the figure.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_13.png" /><br />
<br />
<br />
]]></description>
			<content:encoded><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Structure of a Program that Sorts and Filters the Data</span></span></span><br />
<br />
The <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> data can be sorted and filtered.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_12.png" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">1. Sorting data: sort</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set rg.sort = score DESC</code></div></div><br />
We can use sort to sort the data displayed by <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span>. To do so, we specify the names of the fields to be sorted as character strings. As in this example, when we want to sort the data into descending order, we add DESC after each field name. We can specify multiple fields by delimiting their names with a comma (,).<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set rg.sort = score DESC, age DESC</code></div></div><br />
By using RecordSort, we can specify more complex types of sorting.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">2. Filtering data: filter</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>set rg.filter = {RecordData city = Miami}</code></div></div><br />
To filter the data to be displayed, we use the filter field. To specify the fields and data to be filtered, we use <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span>. Using <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFilter</span></span>, we can specify relatively complex filtering. If we specify null, then no filtering is performed.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">3. Fixing the display region: set-frozen-region</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{rg.set-frozen-region 0,1}</code></div></div><br />
Using set-frozen-region, we can fix the position of the <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> window frame. This prevents the scrolling of the specified lines and columns. There are several other APIs for managing fixed lines and columns. These are described in the Curl API documentation.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">4. Displaying the layout: VBox</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{VBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;rg,<br />
&nbsp;&nbsp;&nbsp;&nbsp;{HBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;sort-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;filter-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;reverse-button<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
As explained above, the final expression specified in the value block is displayed on the screen. In the current example, this <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">VBox</span></span> is the final expression. Therefore, the screen layout will appear as shown in the figure.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_13.png" /><br />
<br />
<br />
]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Page 5: Sorting and Filtering Data]]></title>
			<link>https://communities.curl.com/showthread.php?tid=59</link>
			<pubDate>Thu, 16 Jun 2011 07:27:04 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=59</guid>
			<description><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Application: Sorting and Filtering Data</span></span></span><br />
<br />
<img src="wiki/easy-ide-book/common/images/step1.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the 'Try 3-3' Project</span></span></span><br />
<br />
Close the Try 3-2 project . Next from the IDE 'File' menu, select 'New Project'. In the 'New Project' dialog box, select “Applet Project” (1), input “Try3-3” (2), specify <span style="font-family: Courier;" class="mycode_font">c:\Curl\lesson\Try3\03_sort_filter</span> in the “Directory” field (3), set the<span style="font-family: Courier;" class="mycode_font"> API Version to 6.0</span> (4), and then click OK (5).<br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_10.png" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step2.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Inputting the Program</span></span></span><br />
<br />
Next, we’ll input the program. You can copy the program code below or use <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\03_sort_filter\start.curl</span> and then paste it into the editor in the IDE.<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet =<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField score, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField city, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField tel, domain = String}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Matt, age = 33, score = 88, city = Cambridge, tel = 555-1567},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Sarah, age = 27, score = 79, city = Seattle, tel = 555-5692},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Jacob, age = 26, score = 90, city = Chicago, tel = 555-7259},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Miles, age = 23, score = 98, city = Miami, tel = 555-2644},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Anna, age = 27, score = 81, city = San Diego, tel = 555-9968},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Paul, age = 28, score = 86, city = Denver, tel = 555-6389},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Diana, age = 25, score = 85, city = Atlanta, tel = 555-4712}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;let rg:RecordGrid = {RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&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nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<img src="wiki/easy-ide-book/common/images/step3.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Save the File, and then Execute the Program</span></span></span><br />
<br />
After inputting the code, save the file, and then execute the program. The following result will appear in your browser.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_11.png" /><br />
<br />
]]></description>
			<content:encoded><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Application: Sorting and Filtering Data</span></span></span><br />
<br />
<img src="wiki/easy-ide-book/common/images/step1.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the 'Try 3-3' Project</span></span></span><br />
<br />
Close the Try 3-2 project . Next from the IDE 'File' menu, select 'New Project'. In the 'New Project' dialog box, select “Applet Project” (1), input “Try3-3” (2), specify <span style="font-family: Courier;" class="mycode_font">c:\Curl\lesson\Try3\03_sort_filter</span> in the “Directory” field (3), set the<span style="font-family: Courier;" class="mycode_font"> API Version to 6.0</span> (4), and then click OK (5).<br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_10.png" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step2.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Inputting the Program</span></span></span><br />
<br />
Next, we’ll input the program. You can copy the program code below or use <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\03_sort_filter\start.curl</span> and then paste it into the editor in the IDE.<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet =<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField score, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField city, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordField tel, domain = String}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Matt, age = 33, score = 88, city = Cambridge, tel = 555-1567},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Sarah, age = 27, score = 79, city = Seattle, tel = 555-5692},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Jacob, age = 26, score = 90, city = Chicago, tel = 555-7259},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Miles, age = 23, score = 98, city = Miami, tel = 555-2644},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Anna, age = 27, score = 81, city = San Diego, tel = 555-9968},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Paul, age = 28, score = 86, city = Denver, tel = 555-6389},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{RecordData name = Diana, age = 25, score = 85, city = Atlanta, tel = 555-4712}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;let rg:RecordGrid = {RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-source = data,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;height = 3cm,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb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&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br />
&nbsp;&nbsp;&nbsp;&nbsp;{rg.set-frozen-region 0, 1}<br />
&nbsp;&nbsp;&nbsp;&nbsp;{VBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;rg,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{HBox<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;sort-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;filter-button,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;reverse-button<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<img src="wiki/easy-ide-book/common/images/step3.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Save the File, and then Execute the Program</span></span></span><br />
<br />
After inputting the code, save the file, and then execute the program. The following result will appear in your browser.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_11.png" /><br />
<br />
]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Page 4: Structure of a Program for Setting the RecordGrid's Appearance and Functiona]]></title>
			<link>https://communities.curl.com/showthread.php?tid=58</link>
			<pubDate>Thu, 16 Jun 2011 07:24:26 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=58</guid>
			<description><![CDATA[<img src="wiki/easy-ide-book/common/images/topic.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Structure of a Program for Setting the RecordGrid's Appearance and Functionality</span></span></span><img src="wiki/easy-ide-book/common/images/topic.gif" /><br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_7.png" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">1. Setting function-modifying options such as 'cells-take-focus?'</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>cells-take-focus? = false,<br />
column-movable? = false,<br />
column-resizable? = false,<br />
editable?&nbsp;&nbsp;= false,<br />
multiple-selection-enabled? = false,<br />
record-selection-enabled? = false,<br />
column-selection-enabled? = true,</code></div></div><br />
As we found in Basics 1, <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> has many actions that the user can perform. These can be modified by specifying options. Let’s take a brief look at these options.<br />
<br />
<img src="attachment.php?aid=101" /><br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_8.png" /><br />
<br />
Let’s take a look at what happens when we change the true/false settings.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">2. Setting options that affect the appearance</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>display-filler-column? = true,<br />
display-navigation-panel? = false,<br />
alternate-row-background = #ddeeee,<br />
grid-line-color = #aaaaaa,<br />
horizontal-grid-line-width = 1px,<br />
vertical-grid-line-width = 2px</code></div></div><br />
In (1), we touched on the function-modifying options. Here, we’ll look at those options that are used to change the appearance.<br />
<br />
<img src="attachment.php?aid=109" /><br />
<img src="wiki/easy-ide-book/try3/images/figure_3_9.png" /><br />
<br />
Try changing the values of the above options to see how they affect the appearance.<br />
<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=101" target="_blank" title="">3-3.PNG</a> (Size: 13.04 KB / Downloads: 1432)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=109" target="_blank" title="">3-4.PNG</a> (Size: 19.63 KB / Downloads: 1343)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<img src="wiki/easy-ide-book/common/images/topic.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Structure of a Program for Setting the RecordGrid's Appearance and Functionality</span></span></span><img src="wiki/easy-ide-book/common/images/topic.gif" /><br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_7.png" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">1. Setting function-modifying options such as 'cells-take-focus?'</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>cells-take-focus? = false,<br />
column-movable? = false,<br />
column-resizable? = false,<br />
editable?&nbsp;&nbsp;= false,<br />
multiple-selection-enabled? = false,<br />
record-selection-enabled? = false,<br />
column-selection-enabled? = true,</code></div></div><br />
As we found in Basics 1, <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> has many actions that the user can perform. These can be modified by specifying options. Let’s take a brief look at these options.<br />
<br />
<img src="attachment.php?aid=101" /><br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_8.png" /><br />
<br />
Let’s take a look at what happens when we change the true/false settings.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">2. Setting options that affect the appearance</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>display-filler-column? = true,<br />
display-navigation-panel? = false,<br />
alternate-row-background = #ddeeee,<br />
grid-line-color = #aaaaaa,<br />
horizontal-grid-line-width = 1px,<br />
vertical-grid-line-width = 2px</code></div></div><br />
In (1), we touched on the function-modifying options. Here, we’ll look at those options that are used to change the appearance.<br />
<br />
<img src="attachment.php?aid=109" /><br />
<img src="wiki/easy-ide-book/try3/images/figure_3_9.png" /><br />
<br />
Try changing the values of the above options to see how they affect the appearance.<br />
<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=101" target="_blank" title="">3-3.PNG</a> (Size: 13.04 KB / Downloads: 1432)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=109" target="_blank" title="">3-4.PNG</a> (Size: 19.63 KB / Downloads: 1343)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Page 3: Using Options to Modify the RecordGrid Appearance and Functionality]]></title>
			<link>https://communities.curl.com/showthread.php?tid=57</link>
			<pubDate>Thu, 16 Jun 2011 07:20:42 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=57</guid>
			<description><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Basics 2: Using Options to Modify the RecordGrid Appearance and Functionality</span></span></span><br />
<br />
<img src="wiki/easy-ide-book/common/images/step1.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the 'Try 3-2' Project</span></span></span><br />
<br />
Close the Try 3-1 project . Next from the IDE 'File' menu, select 'New Project'. In the 'New Project' dialog box, select “Applet Project” (1), input “Try3-2” (2), specify <span style="font-family: Courier;" class="mycode_font">c:\Curl\lesson\Try3\02_grid_option</span> in the “Directory” field (3), set the API Version to 6.0 (4), and then click OK (5).<br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_5.png" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step2.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Inputting the Program</span></span></span><br />
<br />
Next, we’ll input the program. You can copy the program code below or use <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\02_grid_option\start.curl</span> and then paste it into the editor in the IDE.<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet = {RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField score, domain = int}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; },<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = Matt, age = 33, score = 88},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = Sarah, age = 27, score = 79},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = Jacob, age = 26, score = 90}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-source = data,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width = 10cm,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;height = 3cm<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Additional options below<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Modify functionality<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cells-take-focus? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;column-movable? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;column-resizable? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;editable?&nbsp;&nbsp;= false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;multiple-selection-enabled? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-selection-enabled? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;column-selection-enabled? = true,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Modify appearance<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;display-filler-column? = true,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;display-navigation-panel? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;alternate-row-background = #ddeeee,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;grid-line-color = #aaaaaa,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;horizontal-grid-line-width = 1px,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;vertical-grid-line-width = 2px<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<img src="wiki/easy-ide-book/common/images/step3.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Save the File, and then Execute the Program</span></span></span><br />
<br />
After inputting the code, save the file, and then execute the program. The following result will appear in your browser. Check that both the appearance and functions have been changed. You will see that the following standard <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> functions cannot be used.<br />
<ul class="mycode_list"><li>Edit data<br />
</li>
<li>Change column width<br />
</li>
<li>Change column sort order<br />
</li>
<li>Line select<br />
</li>
<li>Multiple selection<br />
</li>
</ul>
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_5.png" /><br />
]]></description>
			<content:encoded><![CDATA[<span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Basics 2: Using Options to Modify the RecordGrid Appearance and Functionality</span></span></span><br />
<br />
<img src="wiki/easy-ide-book/common/images/step1.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the 'Try 3-2' Project</span></span></span><br />
<br />
Close the Try 3-1 project . Next from the IDE 'File' menu, select 'New Project'. In the 'New Project' dialog box, select “Applet Project” (1), input “Try3-2” (2), specify <span style="font-family: Courier;" class="mycode_font">c:\Curl\lesson\Try3\02_grid_option</span> in the “Directory” field (3), set the API Version to 6.0 (4), and then click OK (5).<br />
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_5.png" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step2.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Inputting the Program</span></span></span><br />
<br />
Next, we’ll input the program. You can copy the program code below or use <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\02_grid_option\start.curl</span> and then paste it into the editor in the IDE.<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet = {RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField score, domain = int}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; },<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = Matt, age = 33, score = 88},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = Sarah, age = 27, score = 79},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = Jacob, age = 26, score = 90}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-source = data,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width = 10cm,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;height = 3cm<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Additional options below<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Modify functionality<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cells-take-focus? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;column-movable? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;column-resizable? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;editable?&nbsp;&nbsp;= false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;multiple-selection-enabled? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-selection-enabled? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;column-selection-enabled? = true,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|| Modify appearance<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;display-filler-column? = true,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;display-navigation-panel? = false,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;alternate-row-background = #ddeeee,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;grid-line-color = #aaaaaa,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;horizontal-grid-line-width = 1px,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;vertical-grid-line-width = 2px<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<img src="wiki/easy-ide-book/common/images/step3.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Save the File, and then Execute the Program</span></span></span><br />
<br />
After inputting the code, save the file, and then execute the program. The following result will appear in your browser. Check that both the appearance and functions have been changed. You will see that the following standard <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> functions cannot be used.<br />
<ul class="mycode_list"><li>Edit data<br />
</li>
<li>Change column width<br />
</li>
<li>Change column sort order<br />
</li>
<li>Line select<br />
</li>
<li>Multiple selection<br />
</li>
</ul>
<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_5.png" /><br />
]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Page 2: Structure of a Program that Displays a Table in a Grid]]></title>
			<link>https://communities.curl.com/showthread.php?tid=56</link>
			<pubDate>Thu, 16 Jun 2011 07:16:43 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=56</guid>
			<description><![CDATA[<img src="wiki/easy-ide-book/common/images/topic.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Structure of a Program that Displays a Table in a Grid</span></span></span><img src="wiki/easy-ide-book/common/images/topic.gif" /><br />
<br />
To display a table, we need the basic data (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>), as well as the grid (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span>) to be used to display that data. Let’s take a look at the source code:<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_3.png" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">1. Create the data to be displayed: RecordSet</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>let data:RecordSet =<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;...<br />
&nbsp;&nbsp;&nbsp;&nbsp;}</code></div></div><br />
First, we have to create the data (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>) that is to be displayed in a table (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span>). In a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>, the constituent data is organized into records and fields, allowing a client to manage the data in memory. Thus, a user can perform filtering and sorting on a client machine without having to access a database.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_4.png" /><br />
<br />
Next, let’s take a look at <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFields</span></span> and <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span>, which display fields and records, respectively.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">2. Specifying fields: RecordFields</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordField score, domain = int}<br />
}</code></div></div><br />
<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFields</span></span> contains each instance of a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordField</span></span> that makes up a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordField</span></span> is used to specify the name and attributes of a field. In this example, the specified character strings like name and age are field names. A name must be specified for each field. This name is referenced whenever data is added or modified. The specification of attributes like domain is optional. Some examples of attributes are given below.<br />
<br />
<img src="attachment.php?aid=98" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">3. Adding data: RecordData</span></span></span><br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordData name = Matt, age = 33, score = 88},<br />
{RecordData name = Sarah, age = 27, score = 79},<br />
{RecordData name = Jacob, age = 26, score = 90}</code></div></div><br />
Using <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span>, we can add data to a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span> is used to specify the data in each field.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">4. Displaying data: RecordGrid</span></span></span><br />
<br />
Steps (1) to (3) are used to create the data that we refer to as a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. While a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span> specifies data, it has no function for displaying that data on the screen. In Curl, separate APIs are provided to actually display a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. For example, <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> allows you to easily display a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span> in a grid<br />
<br />
<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> incorporates multiple functions. Some examples are given below.<br />
<br />
<img src="attachment.php?aid=100" /><br />
<br />
Also, right-clicking a cell enables operations such as of data filtering, copying, and pasting.<br />
<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=98" target="_blank" title="">3-1.PNG</a> (Size: 14.24 KB / Downloads: 1415)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=100" target="_blank" title="">3-2.PNG</a> (Size: 9.42 KB / Downloads: 1393)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<img src="wiki/easy-ide-book/common/images/topic.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Structure of a Program that Displays a Table in a Grid</span></span></span><img src="wiki/easy-ide-book/common/images/topic.gif" /><br />
<br />
To display a table, we need the basic data (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>), as well as the grid (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span>) to be used to display that data. Let’s take a look at the source code:<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_3.png" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">1. Create the data to be displayed: RecordSet</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>let data:RecordSet =<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;...<br />
&nbsp;&nbsp;&nbsp;&nbsp;}</code></div></div><br />
First, we have to create the data (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>) that is to be displayed in a table (<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span>). In a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>, the constituent data is organized into records and fields, allowing a client to manage the data in memory. Thus, a user can perform filtering and sorting on a client machine without having to access a database.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_4.png" /><br />
<br />
Next, let’s take a look at <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFields</span></span> and <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span>, which display fields and records, respectively.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">2. Specifying fields: RecordFields</span></span></span><br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordField name, domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordField age, domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordField score, domain = int}<br />
}</code></div></div><br />
<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordFields</span></span> contains each instance of a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordField</span></span> that makes up a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordField</span></span> is used to specify the name and attributes of a field. In this example, the specified character strings like name and age are field names. A name must be specified for each field. This name is referenced whenever data is added or modified. The specification of attributes like domain is optional. Some examples of attributes are given below.<br />
<br />
<img src="attachment.php?aid=98" /><br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">3. Adding data: RecordData</span></span></span><br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{RecordData name = Matt, age = 33, score = 88},<br />
{RecordData name = Sarah, age = 27, score = 79},<br />
{RecordData name = Jacob, age = 26, score = 90}</code></div></div><br />
Using <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span>, we can add data to a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordData</span></span> is used to specify the data in each field.<br />
<br />
<span style="font-size: large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">4. Displaying data: RecordGrid</span></span></span><br />
<br />
Steps (1) to (3) are used to create the data that we refer to as a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. While a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span> specifies data, it has no function for displaying that data on the screen. In Curl, separate APIs are provided to actually display a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span>. For example, <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> allows you to easily display a <span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordSet</span></span> in a grid<br />
<br />
<span style="color: #9400D3;" class="mycode_color"><span style="font-family: Courier;" class="mycode_font">RecordGrid</span></span> incorporates multiple functions. Some examples are given below.<br />
<br />
<img src="attachment.php?aid=100" /><br />
<br />
Also, right-clicking a cell enables operations such as of data filtering, copying, and pasting.<br />
<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=98" target="_blank" title="">3-1.PNG</a> (Size: 14.24 KB / Downloads: 1415)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://communities.curl.com/images/attachtypes/image.gif" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=100" target="_blank" title="">3-2.PNG</a> (Size: 9.42 KB / Downloads: 1393)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Page 1: Displaying Data in a Grid]]></title>
			<link>https://communities.curl.com/showthread.php?tid=55</link>
			<pubDate>Thu, 16 Jun 2011 07:11:09 +0000</pubDate>
			<guid isPermaLink="false">https://communities.curl.com/showthread.php?tid=55</guid>
			<description><![CDATA[<img src="wiki/easy-ide-book/common/images/try.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Displaying Data in a Grid</span></span></span><br />
<br />
In this chapter, we’ll take the scores from the Try 2 game, and arrange them into a table. We’ll manage data on names, scores, and ages<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Please download the <span style="font-family: Courier;" class="mycode_font">Try3.zip</span> file by selecting the following link: <span style="font-family: Courier;" class="mycode_font"><a href="http://developers.curl.com/wiki/easy-ide-book/try3/Try3.zip" target="_blank" rel="noopener" class="mycode_url">Try3.zip</a></span>. </span><br />
<br />
Unzip the contents to the <span style="font-family: Courier;" class="mycode_font">C:\Curl directory</span>. This is the working directory for all the examples and exercises contained within this tutorial. Note: If C:\Curl has not already been created, you can create it now.<br />
<br />
<img src="wiki/easy-ide-book/common/images/topic.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Basics 1: Using RecordGrid to Display Data as a Table</span></span></span><img src="wiki/easy-ide-book/common/images/topic.gif" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step1.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the 'Try 3-1' Project</span></span></span><br />
<br />
Close the Try 2 project and then, from the IDE 'File' menu, select 'New Project'. In the 'New Project' dialog box, select “Applet Project” (1), input “Try3-1” (2), specify <span style="font-family: Courier;" class="mycode_font">c:\Curl\lesson\Try3\01_grid</span> in the “Directory” field (3), set the API Version to 6.0 (4), and then click OK (5).<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_1.png" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step2.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Inputting the Program</span></span></span><br />
<br />
Next, we’ll input the program. You can copy the program code below or use <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\01_grid\start.curl</span> and then paste it into the editor in the IDE.<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet = {RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField "name", domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField "age", domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField "score", domain = int}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; },<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = "Matt", age = 33, score = 88},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = "Sarah", age = 27, score = 79},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = "Jacob", age = 26, score = 90}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-source = data,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width = 10cm,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;height = 3cm<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<br />
<img src="wiki/easy-ide-book/common/images/step3.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Save the File, and then Execute the Program</span></span></span><br />
<br />
After inputting the code, save the file, and then execute the program. The following result will appear in your browser.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_2.png" /><br />
]]></description>
			<content:encoded><![CDATA[<img src="wiki/easy-ide-book/common/images/try.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Displaying Data in a Grid</span></span></span><br />
<br />
In this chapter, we’ll take the scores from the Try 2 game, and arrange them into a table. We’ll manage data on names, scores, and ages<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Please download the <span style="font-family: Courier;" class="mycode_font">Try3.zip</span> file by selecting the following link: <span style="font-family: Courier;" class="mycode_font"><a href="http://developers.curl.com/wiki/easy-ide-book/try3/Try3.zip" target="_blank" rel="noopener" class="mycode_url">Try3.zip</a></span>. </span><br />
<br />
Unzip the contents to the <span style="font-family: Courier;" class="mycode_font">C:\Curl directory</span>. This is the working directory for all the examples and exercises contained within this tutorial. Note: If C:\Curl has not already been created, you can create it now.<br />
<br />
<img src="wiki/easy-ide-book/common/images/topic.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Basics 1: Using RecordGrid to Display Data as a Table</span></span></span><img src="wiki/easy-ide-book/common/images/topic.gif" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step1.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Create the 'Try 3-1' Project</span></span></span><br />
<br />
Close the Try 2 project and then, from the IDE 'File' menu, select 'New Project'. In the 'New Project' dialog box, select “Applet Project” (1), input “Try3-1” (2), specify <span style="font-family: Courier;" class="mycode_font">c:\Curl\lesson\Try3\01_grid</span> in the “Directory” field (3), set the API Version to 6.0 (4), and then click OK (5).<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_1.png" /><br />
<br />
<img src="wiki/easy-ide-book/common/images/step2.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Inputting the Program</span></span></span><br />
<br />
Next, we’ll input the program. You can copy the program code below or use <span style="font-family: Courier;" class="mycode_font">c:\Curl\Try3\01_grid\start.curl</span> and then paste it into the editor in the IDE.<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>{value<br />
&nbsp;&nbsp;&nbsp;&nbsp;let data:RecordSet = {RecordSet<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordFields<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField "name", domain = String},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField "age", domain = int},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordField "score", domain = int}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; },<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = "Matt", age = 33, score = 88},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = "Sarah", age = 27, score = 79},<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {RecordData name = "Jacob", age = 26, score = 90}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
&nbsp;&nbsp;&nbsp;&nbsp;{RecordGrid<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;record-source = data,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width = 10cm,<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;height = 3cm<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</code></div></div><br />
<br />
<img src="wiki/easy-ide-book/common/images/step3.gif" /><span style="font-size: x-large;" class="mycode_size"><span style="font-family: Arial;" class="mycode_font"><span style="font-weight: bold;" class="mycode_b">Save the File, and then Execute the Program</span></span></span><br />
<br />
After inputting the code, save the file, and then execute the program. The following result will appear in your browser.<br />
<img src="wiki/easy-ide-book/try3/images/figure_3_2.png" /><br />
]]></content:encoded>
		</item>
	</channel>
</rss>