<?xml version='1.0' encoding='UTF-8' ?>
<rss version="2.0" xml:base="http://www.jarober.com/blog/" xmlns:admin="http://webns.net/mvcb/" xmlns:blogChannel="http://backend.userland.com/blogChannelModule" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:icbm="http://postneo.com/icbm" xmlns:includedComments="http://www.laudably.com/rss2-comments" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:media="http://search.yahoo.com/mrss/" xmlns:pingback="http://madskills.com/public/xml/rss/module/pingback/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/">
	<channel>
		<title>Smalltalk 4 You</title>
		<link>http://www.jarober.com/blog/st4u.ssp</link>
		<description>Smalltalk Evangelist, Industry Watcher</description>
		<webMaster>jarober@gmail.com</webMaster>
		<lastBuildDate>Wed, 16 May 2012 10:25:22 GMT</lastBuildDate>
		<image>
			<url>http://www.jarober.com/images/st4u.jpg</url>
			<title>Smalltalk 4 You</title>
			<link>http://www.jarober.com/blog/st4u.ssp</link>
			<height>300</height>
			<width>300</width>
		</image>
		<itunes:explicit>no</itunes:explicit>
		<itunes:subtitle>Smalltalk 4 You</itunes:subtitle>
		<itunes:author>James Robertson</itunes:author>
		<itunes:summary>Video Tutorials for the Smalltalk language - covering most Smalltalk dialects, but concentrating on Squeak and Pharo.</itunes:summary>
		<language>en-us</language>
		<itunes:keywords>smalltalk,software development, oo, object oriented,visualworks,pharo,squeak</itunes:keywords>
		<itunes:category text="Technology"></itunes:category>
		<itunes:owner>
			<itunes:name>James Robertson</itunes:name>
			<itunes:email>jarober@gmail.com</itunes:email>
		</itunes:owner>
		<itunes:image href="http://www.jarober.com/images/st4u.jpg"></itunes:image>
		<admin:generatorAgent rdf:resource="http://www.cincomsmalltalk.com/CincomSmalltalkWiki/Silt"></admin:generatorAgent>
		<admin:errorReportsTo rdf:resource="mailto:jarober@gmail.com"></admin:errorReportsTo>
		<dc:creator>James A. Robertson</dc:creator>
		<dc:rights>Copyright 2011 James Robertson</dc:rights>
		<dc:date>2012-05-16T10:25:22-04:00</dc:date>
		<icbm:latitude>39.214103</icbm:latitude>
		<icbm:longitude>-76.878807</icbm:longitude>
		<item>
			<title>ST 4U 233: Startup Options for VisualWorks</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_233:_Startup_Options_for_VisualWorks&amp;entry=3514616722</link>
			<category>st4u</category>
			<pubDate>Wed, 16 May 2012 10:25:22 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at some of the startup options for VisualWorks (most of which also apply to ObjectStudio now).  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/hwbrk0-_CaQ">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u233StartupOptionsForVisualworks/st4u233.mp4"><img src="/images/st4u/st4u233-poster.jpg" alt="startup" title="startup" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u233StartupOptionsForVisualworks/st4u233.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u233StartupOptionsForVisualworks/st4u233.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/hwbrk0-_CaQ" frameborder="0" allowfullscreen></iframe>
</p>



<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/startup" rel="tag">startup</a>, <a href="http://www.technorati.com/tag/visualworks" rel="tag">visualworks</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3514616722</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3514616722</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3514616722</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="2833175" type="application/octet-stream" url="http://archive.org/download/St4u233StartupOptionsForVisualworks/st4u233-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 233: Startup Options for VisualWorks</itunes:subtitle>
			<itunes:summary>When you start a VisualWorks image, there are a number of startup command line options.  Today we'll take a brief look at them</itunes:summary>
			<itunes:duration>1:48</itunes:duration>
			<itunes:keywords>smalltalk, visualworks, startup</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 233: Startup Options for VisualWorks</media:title>
				<media:content duration="1:48" fileSize="2833175" type="application/octet-stream" url="http://archive.org/download/St4u233StartupOptionsForVisualworks/st4u233-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3514616722</wfw:comment>
		</item>
		<item>
			<title>ST 4U 232: StartupLoader in Pharo</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_232:_StartupLoader_in_Pharo&amp;entry=3514446239</link>
			<category>st4u</category>
			<pubDate>Mon, 14 May 2012 11:03:59 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at the StartupLoader in Pharo - this is all based on <a href="http://www.pharo-project.org/news?dialog=startuploader-running-startup-scripts-in-pharo">this post from Mariano Martinez Peck</a>.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/5BSy07EkasM">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u232StartuploaderInPharo/st4u232.mp4"><img src="/images/st4u/st4u232-poster.jpg" alt="Startup" title="Startup" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u232StartuploaderInPharo/st4u232.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u232StartuploaderInPharo/st4u232.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/D4acKyoN4wU" frameborder="0" allowfullscreen></iframe>
</p>



<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/pharo" rel="tag">pharo</a>, <a href="http://www.technorati.com/tag/startup" rel="tag">startup</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3514446239</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3514446239</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3514446239</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3484126" type="application/octet-stream" url="http://archive.org/download/St4u232StartuploaderInPharo/st4u232-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 232: StartupLoader in Pharo</itunes:subtitle>
			<itunes:summary>Mariano Martinex Peck has been improving the StartupLoader in Pharo - it's a way of specifying startup scripts for a Pharo image.  Today we'll take a look at it</itunes:summary>
			<itunes:duration>2:20</itunes:duration>
			<itunes:keywords>smalltalk, pharo, startup</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 232: StartupLoader in Pharo</media:title>
				<media:content duration="2:20" fileSize="3484126" type="application/octet-stream" url="http://archive.org/download/St4u232StartuploaderInPharo/st4u232-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3514446239</wfw:comment>
		</item>
		<item>
			<title>ST 4U 231: Code Completion in VA 8.5.1</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_231:_Code_Completion_in_VA_8.5.1&amp;entry=3514180381</link>
			<category>st4u</category>
			<pubDate>Fri, 11 May 2012 09:13:01 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at the upgrades to code completion in VA Smalltalk 8.5.1.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/hOCnlz_OEAw">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u231CodeCompletionInVa8.5.1/st4u231.mp4"><img src="/images/st4u/st4u231-poster.jpg" alt="Code Completion" title="Code Completion" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u231CodeCompletionInVa8.5.1/st4u231.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u231CodeCompletionInVa8.5.1/st4u231.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/hOCnlz_OEAw" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll go back to code completion in VA Smalltalk - there have been a lot of improvements in the 8.5.1 release.  When the video from STIC 2012 is released (check <a href="http://www.stic.st/conferences/stic12/stic12-abstracts/">the conference pages regularly</a>), you should definitely watch it.  In the meantime, let's open up a workspace and have a look.  Notice that we've defined our variables as temps; the code completion support relies on having a valid compilation environment.  If you don't have that, you won't see suggestions:</p>

<p><img src="/images/vafiles/st4u231-1.png" alt="Code Completion" title="Code Completion" /></p>

<p>One of the niftier new things is camel case support.  Try typing in RWS - you should see suggestions immediately, although you can always hit ctrl-space to get them:</p>


<p><img src="/images/vafiles/st4u231-3.png" alt="camel case" title="camel case" /></p>

<p>The new support is smart enough to split on the case changes, and match RWS to ReadWriteStream.  What's really nice is that it also works for keyword messages, splitting both on case and colons.  Try creating an OrderedCollection and then entering aai:
</p>

<p><img src="/images/vafiles/st4u231-2.png" alt="camel case" title="camel case" /></p>


<p>Notice that it matched for messages in the collection hierarchy - the support takes note of the compilation environment, and uses it to give you better answers.</p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/code completion" rel="tag">code completion</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3514180381</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3514180381</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3514180381</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="2885523" type="application/octet-stream" url="http://archive.org/download/St4u231CodeCompletionInVa8.5.1/st4u231-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 231: Code Completion in VA 8.5.1</itunes:subtitle>
			<itunes:summary>Instantiations has really improved the code completion support in VA 8.5.1; today we'll look at some of that.</itunes:summary>
			<itunes:duration>2:02</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, code completion</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 231: Code Completion in VA 8.5.1</media:title>
				<media:content duration="2:02" fileSize="2885523" type="application/octet-stream" url="http://archive.org/download/St4u231CodeCompletionInVa8.5.1/st4u231-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3514180381</wfw:comment>
		</item>
		<item>
			<title>ST 4U 230: Using OCX Controls in WindowBuilder</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_230:_Using_OCX_Controls_in_WindowBuilder&amp;entry=3514003540</link>
			<category>st4u</category>
			<pubDate>Wed, 09 May 2012 08:05:40 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at utilizing OCX controls in WindowBuilder Pro (VA Smalltalk) - we've already looked at using them via the Composition Editor.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/gH-7VzFug-Y">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u230UsingOcxControlsInWindowbuilder/st4u230.mp4"><img src="/images/st4u/st4u230-poster.jpg" alt="OCX in WB Pro" title="OCX in WB Pro" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u230UsingOcxControlsInWindowbuilder/st4u230.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u230UsingOcxControlsInWindowbuilder/st4u230.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/gH-7VzFug-Y" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll use WindowBuilder Pro to embed an OCX control into a VA Smalltalk window.  Obviously, this support is limited to Windows.  To get started, select the OLE controls in the palette, and then select the control:</p>

<p><img src="/images/vafiles/st4u230-1.png" alt="OCX Control" title="OCX Control" /></p>

<p>Double click on the widget to bring up properties; it might take a moment, depending on what you have installed.  In clientName, select the control you want to use - the list will vary based on what you have installed on your windows machine.  Here, we've selected the Windows Media Player:</p>


<p><img src="/images/vafiles/st4u230-2.png" alt="windows media" title="windows media" /></p>

<p>To see it work, put in an url for playable media (Video or audio):</p>
</p>

<p><img src="/images/vafiles/st4u230-3.png" alt="properties" title="properties" /></p>



<p>Unlike the composition editor, the embedded player starts operating on what you entered immediately.   You can also test it:</p>



<p><img src="/images/vafiles/st4u230-4.png" alt="playing" title="playing" /></p>



<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/ocx" rel="tag">ocx</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3514003540</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3514003540</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3514003540</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3580767" type="application/octet-stream" url="http://archive.org/download/St4u230UsingOcxControlsInWindowbuilder/st4u230-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 230: Using OCX Controls in WindowBuilder</itunes:subtitle>
			<itunes:summary>We looked at using OCX controls in the VA Composition Editor; today we'll do the same thing in WB Pro.</itunes:summary>
			<itunes:duration>1:44</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, ocx</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 230: Using OCX Controls in WindowBuilder</media:title>
				<media:content duration="1:44" fileSize="3580767" type="application/octet-stream" url="http://archive.org/download/St4u230UsingOcxControlsInWindowbuilder/st4u230-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3514003540</wfw:comment>
		</item>
		<item>
			<title>ST 4U 229: Message Construction</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_229:_Message_Construction&amp;entry=3513830765</link>
			<category>st4u</category>
			<pubDate>Mon, 07 May 2012 08:06:05 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at ad hoc message construction in Smalltalk.  It's a powerful technique, but one that should be used sparingly.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/wZXblrr2-Is">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u229MessageConstruction/st4u229.mp4"><img src="/images/st4u/st4u229-poster.jpg" alt="Message Construction" title="Message Construction" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u229MessageConstruction/st4u229.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u229MessageConstruction/st4u229.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/wZXblrr2-Is" frameborder="0" allowfullscreen></iframe>
</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/perform" rel="tag">perform</a>, <a href="http://www.technorati.com/tag/dynamic message" rel="tag">dynamic message</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3513830765</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3513830765</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3513830765</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3796941" type="application/octet-stream" url="http://archive.org/download/St4u229MessageConstruction/st4u229-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 229: Message Construction</itunes:subtitle>
			<itunes:summary>Using string concatenation, symbols, and perform, you can dynamically create messages to send.  This is a powerful, but risky capability in Smalltalk.  Today we'll take a look at a simple example.</itunes:summary>
			<itunes:duration>2:22</itunes:duration>
			<itunes:keywords>perform, dynamic message, smalltalk</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 229: Message Construction</media:title>
				<media:content duration="2:22" fileSize="3796941" type="application/octet-stream" url="http://archive.org/download/St4u229MessageConstruction/st4u229-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3513830765</wfw:comment>
		</item>
		<item>
			<title>ST 4U 228: Using OCX Controls in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_228:_Using_OCX_Controls_in_VA_Smalltalk&amp;entry=3513581540</link>
			<category>st4u</category>
			<pubDate>Fri, 04 May 2012 10:52:20 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at changing the font used across the tools in VA Smalltalk.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/7ISo5wMeHOI">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u228UsingOcxControlsInVaSmalltalk/st4u228.mp4"><img src="/images/st4u/st4u228-poster.jpg" alt="OCX" title="OCX" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u228UsingOcxControlsInVaSmalltalk/st4u228.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u228UsingOcxControlsInVaSmalltalk/st4u228.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/7ISo5wMeHOI" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll use the Composition editor to embed an OCX control into a VA Smalltalk window.  Obviously, this support is limited to Windows.  To get started, select the OLE folder in the composition editor, and then use the middle control:</p>

<p><img src="/images/vafiles/st4u228-1.png" alt="OCX Control" title="OCX Control" /></p>

<p>Double click on the part you just selected to set properties.  In clientName, select the control you want to use - the list will vary based on what you have installed on your windows machine.  Here, we've selected the Windows Media Player:</p>


<p><img src="/images/vafiles/st4u228-2.png" alt="windows media" title="windows media" /></p>

<p>Next, close the properties tool and reopen it.  The player will render in the canvas, and its specific properties will become available:
</p>

<p><img src="/images/vafiles/st4u228-3.png" alt="properties" title="properties" /></p>



<p>You can specify various control properties; here, we'll set the URL, so that the player opens on some media.  In this case, we'll use a podcast mp3 file.  Using the test functionality, you can see it work:</p>



<p><img src="/images/vafiles/st4u228-4.png" alt="playing" title="playing" /></p>



<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/ocx" rel="tag">ocx</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3513581540</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3513581540</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3513581540</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4003050" type="application/octet-stream" url="http://archive.org/download/St4u228UsingOcxControlsInVaSmalltalk/st4u228-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 228: Using OCX Controls in VA Smalltalk</itunes:subtitle>
			<itunes:summary>Today we'll use the composition editor to embed an OCX control into a VA Smalltalk window</itunes:summary>
			<itunes:duration>1:29</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, ocx, parts</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 228: Using OCX Controls in VA Smalltalk</media:title>
				<media:content duration="1:29" fileSize="4003050" type="application/octet-stream" url="http://archive.org/download/St4u228UsingOcxControlsInVaSmalltalk/st4u228-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3513581540</wfw:comment>
		</item>
		<item>
			<title>ST 4U 227: Launching an External Application in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_227:_Launching_an_External_Application_in_VA_Smalltalk&amp;entry=3513408981</link>
			<category>st4u</category>
			<pubDate>Wed, 02 May 2012 10:56:21 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at launching an external application (a browser in this example) from a VA Smalltalk application.  We'll use the composition editor to build our example app.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/3FaWJNrfg7A">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u227LaunchingAnExternalApplication/st4u227.mp4"><img src="/images/st4u/st4u227-poster.jpg" alt="external app" title="external app" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u227LaunchingAnExternalApplication/st4u227.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u227LaunchingAnExternalApplication/st4u227.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/3FaWJNrfg7A" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll use the Composition editor to hook up a button in a VA Smalltalk application to an external application - in this case, a web browser that defaults to a specific page. To get started, select the external applications folder in the tool, and then use the external application icon.  Drop an instance outside the bounds of the window, as we are going to connect a window component (button) to it:</p>

<p><img src="/images/vafiles/st4u227-1.png" alt="External Application" title="External Application" /></p>

<p>Double click on the part you just selected to set properties.  Use the "find" button to locate the application that will be launched.  Note that you can specify a parameter string; here, we'll use an url:</p>


<p><img src="/images/vafiles/st4u227-2.png" alt="properties" title="properties" /></p>

<p>Here we have everything specified:
</p>

<p><img src="/images/vafiles/st4u227-3.png" alt="properties" title="properties" /></p>



<p>Now, put a button on the canvas, and connect that to the "start program" aspect of the external application:</p>



<p><img src="/images/vafiles/st4u227-4.png" alt="connect" title="connect" /></p>

<p>If you set it all up correctly, you should see something like this when you use the test functionality and click the button:</p>

<p><img src="/images/vafiles/st4u227-5.png" alt="test" title="test" /></p>


<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/parts" rel="tag">parts</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3513408981</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3513408981</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3513408981</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="2696200" type="application/octet-stream" url="http://archive.org/download/St4u227LaunchingAnExternalApplication/st4u227-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 227: Launching an External Application in VA Smalltalk</itunes:subtitle>
			<itunes:summary>Today we'll use the composition editor to hook up a VA window button to an external program - clicking the button will launch a browser</itunes:summary>
			<itunes:duration>1:47</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, parts</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 227: Launching an External Application in VA Smalltalk</media:title>
				<media:content duration="1:47" fileSize="2696200" type="application/octet-stream" url="http://archive.org/download/St4u227LaunchingAnExternalApplication/st4u227-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3513408981</wfw:comment>
		</item>
		<item>
			<title>ST 4U 226: Message Not Understood</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_226:_Message_Not_Understood&amp;entry=3513232186</link>
			<category>st4u</category>
			<pubDate>Mon, 30 Apr 2012 09:49:46 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at handling the MessageNotUnderstood exception - by implementing #doesNotUnderstand:.  It's a dangerous thing to do, but can sometimes be useful.  Today we use a trivial example to demonstrate.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/-4eD7e97pQs">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u226MessageNotUnderstood/st4u226.mp4"><img src="/images/st4u/st4u226-poster.jpg" alt="MNU" title="MNU" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u226MessageNotUnderstood/st4u226.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u226MessageNotUnderstood/st4u226.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/-4eD7e97pQs" frameborder="0" allowfullscreen></iframe>
</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/mnu" rel="tag">mnu</a>, <a href="http://www.technorati.com/tag/error handling" rel="tag">error handling</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3513232186</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3513232186</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3513232186</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4025760" type="application/octet-stream" url="http://archive.org/download/St4u226MessageNotUnderstood/st4u226-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 226: Message Not Understood</itunes:subtitle>
			<itunes:summary>One of the cool things about Smalltalk is the ability to handle nearly anything - including messages that are not understood.  It's a risky thing to implement #doesNotUnderstand:, but we'll take a look at a simple example today</itunes:summary>
			<itunes:duration>2:50</itunes:duration>
			<itunes:keywords>smalltalk, MNU, error handling</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 226: Message Not Understood</media:title>
				<media:content duration="2:50" fileSize="4025760" type="application/octet-stream" url="http://archive.org/download/St4u226MessageNotUnderstood/st4u226-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3513232186</wfw:comment>
		</item>
		<item>
			<title>ST 4U 225: Embedding a Windows Application in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_225:_Embedding_a_Windows_Application_in_VA_Smalltalk&amp;entry=3512976918</link>
			<category>st4u</category>
			<pubDate>Fri, 27 Apr 2012 10:55:18 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at embedding a standard windows app (WordPad in this case) into a VA Smalltalk window.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/UHPhhPmlArk">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u225EmbeddingAWindowsApplicationInVaSmalltalk/st4u225.mp4"><img src="/images/st4u/st4u225-poster.jpg" alt="OLE" title="OLE" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u225EmbeddingAWindowsApplicationInVaSmalltalk/st4u225.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u225EmbeddingAWindowsApplicationInVaSmalltalk/st4u225.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/t-0BUC-zI2g" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll use the VA OLE support to embed a Windows application into a VA Smalltalk window.  We'll use a standard editor - WordPad.  To get started, open the VA Organizer, create a new application and part, and add in an OLE client control (To see those steps, refer to <a href="blogView?entry=3512803031">this tutorial</a>. </p>

<p><img src="/images/vafiles/st4u225-1.png" alt="OLE Client" title="OLE Client" /></p>

<p>Double click on the client part, scroll down to "clientName", and select one of the available options from the drop down.  THe list will vary based on what you have installed on your system; we'll pick WordPad, which should always be available:</p>


<p><img src="/images/vafiles/st4u225-2.png" alt="client" title="client" /></p>

<p>Next, we'll change decorationPolicy and focusDecorationPolicy to XmNONE - this will remove any application borders, embedding the tool completely into our window:
</p>

<p><img src="/images/vafiles/st4u225-3.png" alt="display" title="display" /></p>



<p>Finally, go to File&gt;&gt;Test, and see the embedding in action:</p>



<p><img src="/images/vafiles/st4u225-4.png" alt="OLE Editor" title="OLE Editor" /></p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/ole" rel="tag">ole</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3512976918</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3512976918</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3512976918</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3437587" type="application/octet-stream" url="http://archive.org/download/St4u225EmbeddingAWindowsApplicationInVaSmalltalk/st4u225-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 225: Embedding a Windows Application in VA Smalltalk</itunes:subtitle>
			<itunes:summary>Today we'll use OLE in VA Smalltalk to embed WordPad into a VA Smalltalk window</itunes:summary>
			<itunes:duration>2:05</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, ole</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 225: Embedding a Windows Application in VA Smalltalk</media:title>
				<media:content duration="2:05" fileSize="3437587" type="application/octet-stream" url="http://archive.org/download/St4u225EmbeddingAWindowsApplicationInVaSmalltalk/st4u225-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3512976918</wfw:comment>
		</item>
		<item>
			<title>ST 4U 224: Getting Started With OLE Controls in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_224:_Getting_Started_With_OLE_Controls_in_VA_Smalltalk&amp;entry=3512803031</link>
			<category>st4u</category>
			<pubDate>Wed, 25 Apr 2012 10:37:11 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> starts looking at OLE interfaces in VA Smalltalk, starting with something very simple - a graphics pane on a bitmap.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/wN2m8neKm2U">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u224GettingStartedWithOleControlsInVaSmalltalk/st4u224.mp4"><img src="/images/st4u/st4u224-poster.jpg" alt="OLE" title="OLE" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u224GettingStartedWithOleControlsInVaSmalltalk/st4u224.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u224GettingStartedWithOleControlsInVaSmalltalk/st4u224.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/wN2m8neKm2U" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll start looking at using OLE components in VA Smalltalk - starting off with the simplest example possible: using the graphics control to display a bitmap graphic.  First, load the OLE support (VA OLE support) from the features tool: </p>

<p><img src="/images/vafiles/st4u224-1.png" alt="Features" title="Features" /></p>

<p>Next, open up the VA Organizer and create a new application and (visual) part:</p>


<p><img src="/images/vafiles/st4u224-2.png" alt="New Part" title="New Part" /></p>

<p>That will take you to the composition editor.  On the lower left side of the tools section, you should see a new "OLE" category.  Select that, and then pick the first (OLE Client) control from the list:
</p>

<p><img src="/images/vafiles/st4u224-3.png" alt="OLE Parts" title="OLE Parts" /></p>


<p>Right click on the part, and go to settings.  Towards the bottom, you should see "sourcePath".  We are going to hit the chooser, and select the BMP file to drop in here.</p>


<p><img src="/images/vafiles/st4u224-4.png" alt="OLE Client" title="OLE Client" /></p>

<p>It should render immediately:</p>

<p><img src="/images/vafiles/st4u224-5.png" alt="OLE Graphic" title="OLE Graphic" /></p>

<p>Finally, go to the File menu and select "Test".  You should see your graphic in a new window:</p>

<p><img src="/images/vafiles/st4u224-6.png" alt="OLE Graphic" title="OLE Graphic" /></p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/ole" rel="tag">ole</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3512803031</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3512803031</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3512803031</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4244122" type="application/octet-stream" url="http://archive.org/download/St4u224GettingStartedWithOleControlsInVaSmalltalk/st4u224-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 224: Getting Started With OLE Controls in VA Smalltalk</itunes:subtitle>
			<itunes:summary>Today we'll use a really simple OLE control - a simple image pane - to get started with OLE in VA Smalltalk</itunes:summary>
			<itunes:duration>2:18</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, ole</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 224: Getting Started With OLE Controls in VA Smalltalk</media:title>
				<media:content duration="2:18" fileSize="4244122" type="application/octet-stream" url="http://archive.org/download/St4u224GettingStartedWithOleControlsInVaSmalltalk/st4u224-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3512803031</wfw:comment>
		</item>
		<item>
			<title>ST 4U 223: Allocation Profiling in VisualWorks</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_223:_Allocation_Profiling_in_VisualWorks&amp;entry=3512627894</link>
			<category>st4u</category>
			<pubDate>Mon, 23 Apr 2012 09:58:14 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at the allocation profiler in VisualWorks (the same tool is available for ObjectStudio).  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/C0e3JU5op5o">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u223AllocationProfilingInVisualworks/st4u223.mp4"><img src="/images/st4u/st4u223-poster.jpg" alt="allocations" title="allocations" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u223AllocationProfilingInVisualworks/st4u223.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u223AllocationProfilingInVisualworks/st4u223.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/C0e3JU5op5o" frameborder="0" allowfullscreen></iframe>
</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/visualworks" rel="tag">visualworks</a>, <a href="http://www.technorati.com/tag/profiling" rel="tag">profiling</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3512627894</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3512627894</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3512627894</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3142153" type="application/octet-stream" url="http://archive.org/download/St4u223AllocationProfilingInVisualworks/st4u223-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 223: Allocation Profiling in VisualWorks</itunes:subtitle>
			<itunes:summary>Need to profile a segment of code for memory performance in VisualWorks or ObjectStudio?  Today we'll take a look at the Allocation profiling tools.</itunes:summary>
			<itunes:duration>1:35</itunes:duration>
			<itunes:keywords>smalltalk, profiling, visualworks</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 223: Allocation Profiling in VisualWorks</media:title>
				<media:content duration="1:35" fileSize="3142153" type="application/octet-stream" url="http://archive.org/download/St4u223AllocationProfilingInVisualworks/st4u223-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3512627894</wfw:comment>
		</item>
		<item>
			<title>ST 4U 222: A Look Around the Composition Editor</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_222:_A_Look_Around_the_Composition_Editor&amp;entry=3512362085</link>
			<category>st4u</category>
			<pubDate>Fri, 20 Apr 2012 08:08:05 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> takes a look at some of the ways that VA Assist Pro helps out with the Composition Editor.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/EC2ozj3WNnY">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u222ALookAroundTheCompositionEditor/st4u222.mp4"><img src="/images/st4u/st4u222-poster.jpg" alt="VA Assist Pro" title="VA Assist Pro" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u222ALookAroundTheCompositionEditor/st4u222.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u222ALookAroundTheCompositionEditor/st4u222.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/EC2ozj3WNnY" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll look at where the widgets that you use in the Parts tool are picked and placed, and how VA Assist Pro makes that task a bit easier.  To start with, examine the left hand side of the screen.  The toolbars on the left have widgets: the leftmost is categories.  Select one, and you get widgets in that "Set": </p>

<p><img src="/images/vafiles/st4u222-1.png" alt="Widgets" title="Widgets" /></p>

<p>Quite often, you'll want some of the more commonly used parts - and that's where VA Assist Pro comes in.  Open that up from the "Options" menu:</p>


<p><img src="/images/vafiles/st4u222-2.png" alt="VA Assist" title="VA Assist" /></p>

<p>If you switch to the "Parts" tab, you'll see some of the more commonly used widgets.  This often makes it easier to build UIs, as they will mostly be made up of stock parts:</p>
</p>

<p><img src="/images/vafiles/st4u222-3.png" alt="Common Parts" title="Common Parts" /></p>


<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/parts" rel="tag">parts</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3512362085</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3512362085</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3512362085</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="2440185" type="application/octet-stream" url="http://archive.org/download/St4u222ALookAroundTheCompositionEditor/st4u222-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 222: A Look Around the Composition Editor</itunes:subtitle>
			<itunes:summary>Today we'll step back from the example application, and take a look at some of the ways to make it easier to interact with the Composition Editor - starting with VA Assist Pro.</itunes:summary>
			<itunes:duration>1:26</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, parts</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 222: A Look Around the Composition Editor</media:title>
				<media:content duration="1:26" fileSize="2440185" type="application/octet-stream" url="http://archive.org/download/St4u222ALookAroundTheCompositionEditor/st4u222-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3512362085</wfw:comment>
		</item>
		<item>
			<title>ST 4U 221: Limiting Your Connections Viewed</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_221:_Limiting_Your_Connections_Viewed&amp;entry=3512189686</link>
			<category>st4u</category>
			<pubDate>Wed, 18 Apr 2012 08:14:46 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> digs into the Composition Editor in VA Smalltalk again.  It's easy to add enough connections to make things a bit confusing - fortunately, you can filter them in various ways.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/wPqNgmN53no">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u221LimitingYourConnectionsViewed/st4u221.mp4"><img src="/images/st4u/st4u221-poster.jpg" alt="Connection Filtering" title="Connection Filtering" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u221LimitingYourConnectionsViewed/st4u221.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u221LimitingYourConnectionsViewed/st4u221.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/wPqNgmN53no" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll look at filtering the connections view in the composition editor.  While our simple example has a small number of connections, it will serve to demonstrate how you can filter out what you do and don't want to see.  First, pull down the "Connections" menu:</p>

<p><img src="/images/vafiles/st4u221-1.png" alt="Connections" title="Connections" /></p>

<p>By default, you'll be seeing all connections.  Try selecting "Hide all Connections":</p>


<p><img src="/images/vafiles/st4u221-2.png" alt="Hide Connections" title="Hide Connections" /></p>

<p>Now we are looking at a canvas with just our parts on it.  At this point, we can return to the same menu and start turning connections selectively on - for instance, just the events:</p>
</p>

<p><img src="/images/vafiles/st4u221-3.png" alt="Event Connections" title="Event Connections" /></p>


<p>Or just the attribute connections:</p>


<p><img src="/images/vafiles/st4u221-4.png" alt="attribute connections" title="attribute connections" /></p>

<p>By doing this, we can examine our connections in detail and not get lost in the full complexity.  You can also tell what's going on at a glance - note that event connectors are green,  while attribute connectors are blue.</p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/parts" rel="tag">parts</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3512189686</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3512189686</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3512189686</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="2062913" type="application/octet-stream" url="http://archive.org/download/St4u221LimitingYourConnectionsViewed/st4u221-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 221: Limiting Your Connections Viewed</itunes:subtitle>
			<itunes:summary>Once you've built a more complex part in VA Smalltalk, the connections can get to be visually overwhelming.  Fortunately, you can filter the view easily.</itunes:summary>
			<itunes:duration>1:25</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, parts</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 221: Limiting Your Connections Viewed</media:title>
				<media:content duration="1:25" fileSize="2062913" type="application/octet-stream" url="http://archive.org/download/St4u221LimitingYourConnectionsViewed/st4u221-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3512189686</wfw:comment>
		</item>
		<item>
			<title>ST 4U 220: Time Profiling in VisualWorks</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_220:_Time_Profiling_in_VisualWorks&amp;entry=3512020792</link>
			<category>st4u</category>
			<pubDate>Mon, 16 Apr 2012 09:19:52 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at the Time profiler in VisualWorks.  The same tool works in ObjectStudio, even though that's not being shown here.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/mDFdYSQR7aA">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u220TimeProfilingInVisualworks/st4u220.mp4"><img src="/images/st4u/st4u220-poster.jpg" alt="Profiling" title="Profiling" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u220TimeProfilingInVisualworks/st4u220.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u220TimeProfilingInVisualworks/st4u220.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/mDFdYSQR7aA" frameborder="0" allowfullscreen></iframe>
</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/visualworks" rel="tag">visualworks</a>, <a href="http://www.technorati.com/tag/profiling" rel="tag">profiling</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3512020792</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3512020792</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3512020792</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4143980" type="application/octet-stream" url="http://archive.org/download/St4u220TimeProfilingInVisualworks/st4u220-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 220: Time Profiling in VisualWorks</itunes:subtitle>
			<itunes:summary>Need to profile a segment of code for performance in VisualWorks or ObjectStudio?  Today we'll take a look at the Time profiling tools.</itunes:summary>
			<itunes:duration>2:20</itunes:duration>
			<itunes:keywords>smalltalk, profiling, visualworks</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 220: Time Profiling in VisualWorks</media:title>
				<media:content duration="2:20" fileSize="4143980" type="application/octet-stream" url="http://archive.org/download/St4u220TimeProfilingInVisualworks/st4u220-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3512020792</wfw:comment>
		</item>
		<item>
			<title>ST 4U 219: Creating a Visual Part in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_219:_Creating_a_Visual_Part_in_VA_Smalltalk&amp;entry=3511767108</link>
			<category>st4u</category>
			<pubDate>Fri, 13 Apr 2012 10:51:48 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> adds a UI that connects to the timer (non visual) part we created last time.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/i1-d3Uks_MM">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u219CreatingAVisualPartInVaSmalltalk/st4u219.mp4"><img src="/images/st4u/st4u219-poster.jpg" alt="Parts" title="parts" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u219CreatingAVisualPartInVaSmalltalk/st4u219.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u219CreatingAVisualPartInVaSmalltalk/st4u219.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/i1-d3Uks_MM" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll create a visual part in VA Smalltalk, and hook it up to the non-visual part we created last time.  Here's the end result - we'll walk through the steps, taking the connections one by one, from the top of the screen down:</p>

<p><img src="/images/vafiles/st4u219-1.png" alt="Connections" title="Connections" /></p>

<p>First, how did we add the non-visual part?  We used the "add part" menu option in the composition editor, and selected the part by browsing for the name.  It appears as a "puzzle piece", since there's no UI.  To connect up the #timerFired event to a script, right click on the part, and select "connect".  When presented with options, select the script - you'll add a #beep method:</p>


<p><img src="/images/vafiles/st4u219-8.png" alt="Beep" title="Beep" /></p>

<p>The code for that is as follows:</p>

<p>
<pre>

beep
	CgDisplay default bell: 20

</pre>
</p>

<p>That will simply play a tone when the timer fires - that way we can tell whether our hookups worked.  The properties for this look like this:  </p>

<p><img src="/images/vafiles/st4u219-3.png" alt="Connection" title="Connection" /></p>

<p>To get the UI parts on the canvas, simply select them in the toolbar at the top of the window, click on the canvas below, and move them around.  To set properties, double click - you'll need to set the input field to be an integer, for instance.</p>


<p>Next, create a connection from the input field to the timer object.  Hook up the "Object" (value) attribute of the field to the length attribute of the timer.  Now when we enter a value, it will flow to the timer object:</p>

<p><img src="/images/vafiles/st4u219-4.png" alt="length" title="length" /></p>

<p>Now create a connection from the checkbox to the repeat attribute (which we set up as a boolean) in the timer.  If checked, this will run our timer repeatedly:</p>

<p><img src="/images/vafiles/st4u219-5.png" alt="repeat" title="repeat" /></p>

<p>Next, we need to hook up the start and stop buttons.  Create one connection for each to the timer - hook up "clicked" to the start and stop actions respectively:</p>

<p><img src="/images/vafiles/st4u219-6.png" alt="Start" title="Start" /></p>

<p><img src="/images/vafiles/st4u219-7.png" alt="Stop" title="Stop" /></p>

<p>Now use the Test menu option.  The UI should come up.  Enter 1000 (this is milliseconds) in the input field, and then hit the start button.  You should get a tone if you have it all set up properly.</p>

<p><img src="/images/vafiles/st4u219-8.png" alt="App" title="App" /></p>

<p>That just about wraps it up - version this off in ENVY so you can continue with it later - you've just hooked up your visual and non-visual parts in VA Smalltalk.</p>

<p><img src="/images/vafiles/st4u218-11.png" alt="Save" title="Save" /></p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/parts" rel="tag">parts</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3511767108</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3511767108</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3511767108</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="5613950" type="application/octet-stream" url="http://archive.org/download/St4u219CreatingAVisualPartInVaSmalltalk/st4u219-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 219: Creating a Visual Part in VA Smalltalk</itunes:subtitle>
			<itunes:summary>Today we'll continue with the parts editor in VA Smalltalk, by hooking up a new visual part to our previously created non-visual part</itunes:summary>
			<itunes:duration>3:26</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, parts</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 219: Creating a Visual Part in VA Smalltalk</media:title>
				<media:content duration="3:26" fileSize="5613950" type="application/octet-stream" url="http://archive.org/download/St4u219CreatingAVisualPartInVaSmalltalk/st4u219-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3511767108</wfw:comment>
		</item>
		<item>
			<title>ST 4U 218: Creating a Non-Visual Part in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_218:_Creating_a_Non-Visual_Part_in_VA_Smalltalk&amp;entry=3511599764</link>
			<category>st4u</category>
			<pubDate>Wed, 11 Apr 2012 12:22:44 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at creating a new part (non-visual) using the VA Smalltalk parts editing tools.  In the next screencast, we'll use the part created here in a UI.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/r_cvYvnLNYs">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u218CreatingANon-visualPartInVaSmalltalk/st4u218.mp4"><img src="/images/st4u/st4u218-poster.jpg" alt="Parts" title="Parts" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u218CreatingANon-visualPartInVaSmalltalk/st4u218.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u218CreatingANon-visualPartInVaSmalltalk/st4u218.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/r_cvYvnLNYs" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll create a non-visual part in VA Smalltalk.  IN our next tutorial, we'll integrate this part into a visual one.  To get started, open the organizer - which opens automatically in a new VA image:</p>


<p><img src="/images/vafiles/st4u218-1.png" alt="Organizer" title="Organizer" /></p>

<p>Enter an application name, let the rest default, and hit ok.  When the Composition editor opens, you can close that - we won't need it yet.  Instead, from the defining window, create a new part.  Give it a name, and set it to be non-visual:</p>

<p><img src="/images/vafiles/st4u218-2.png" alt="Part" title="Part" /></p>

<p>In the View menu, switch to the public interface editor.  We need to add some attributes (instance variables), actions, and events.  For the latter ones we'll be using the script editor to add Smalltalk code.  </p>

<p><img src="/images/vafiles/st4u218-3.png" alt="Script Editor" title="Script Editor" /></p>

<p>Add length and repeat.  For repeat, set the object type to Boolean.  Then change the tab (top of the tool) to events - we need to add an event, timerFired:</p>

<p><img src="/images/vafiles/st4u218-4.png" alt="Events" title="Events" /></p>

<p>Next, change the tab to actions, and set up stop and start as actions (they will start and stop the timer):</p>

<p><img src="/images/vafiles/st4u218-5.png" alt="Actions" title="Actions" /></p>

<p>Now that we've done all of that, pull down the "File" menu, and select "Generate Default Scripts".  You should see the following:</p>

<p><img src="/images/vafiles/st4u218-6.png" alt="Generate" title="Generate" /></p>

<p><img src="/images/vafiles/st4u218-7.png" alt="Generation Options" title="Generation Options" /></p>

<p>Hit Ok, and then we can open a browser up and see what we have:</p>

<p><img src="/images/vafiles/st4u218-8.png" alt="Browser" title="Browser" /></p>

<p>While you're in the browser, add an instance variable - "timer".  That will be the actual timer object.  Once we have that, we need to go back to the editor, and change back to the script view.  We'll now add some methods for #start, #stop, and #timerFired (the latter being the event that happens when our timer goes off):</p>

<p><img src="/images/vafiles/st4u218-9.png" alt="Script Editor" title="Script Editor" /></p>

<p>The code you'll add is below.  For each method, select "New Method Template" from the method menu, and then add the code.  You can also just add these in the stock browser; either way, they end up in the same place:</p>

<p><img src="/images/vafiles/st4u218-10.png" alt="Script Editor" title="Script Editor" /></p>

<p>
<pre>

start
	"Perform the start action."

	timer := CwAppContext default
					addTimeout: self length
					receiver: self
					selector: #eventTimerFired:
					clientData: nil.

stop
	"Perform the stop action."
	
	timer notNil ifTrue: [CwAppContext default
	removeTimeout: timer ].

eventTimerFired: anObject
	"Notify other parts that the timer has expired."

	self signalEvent: #timerFired.
	timer := nil.
	self repeat ifTrue: [self start].

</pre>
</p>

<p>That just about wraps it up - version this off in ENVY so we can continue with it later - you've just created a reusable, non-visual part in VA Smalltalk.</p>

<p><img src="/images/vafiles/st4u218-11.png" alt="Save" title="Save" /></p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/parts" rel="tag">parts</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3511599764</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3511599764</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3511599764</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="8828722" type="application/octet-stream" url="http://archive.org/download/St4u218CreatingANon-visualPartInVaSmalltalk/st4u218-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 218: Creating a Non-Visual Part in VA Smalltalk</itunes:subtitle>
			<itunes:summary>Today we'll start taking a look at the Parts editing tools in VA Smalltalk, starting with a simple non-visual part.</itunes:summary>
			<itunes:duration>4:48</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, parts</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 218: Creating a Non-Visual Part in VA Smalltalk</media:title>
				<media:content duration="4:48" fileSize="8828722" type="application/octet-stream" url="http://archive.org/download/St4u218CreatingANon-visualPartInVaSmalltalk/st4u218-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3511599764</wfw:comment>
		</item>
		<item>
			<title>ST 4U 217: Searchlight</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_217:_Searchlight&amp;entry=3511416508</link>
			<category>st4u</category>
			<pubDate>Mon, 09 Apr 2012 09:28:28 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at the Searchlight tools in VisualWorks (also available in ObjectStudio).  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/EUIitG4f_yc">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u217Searchlight/st4u217.mp4"><img src="/images/st4u/st4u217-poster.jpg" alt="Searching" title="Searching" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u217Searchlight/st4u217.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u217Searchlight/st4u217.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/EUIitG4f_yc" frameborder="0" allowfullscreen></iframe>
</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/searchlight" rel="tag">searchlight</a>, <a href="http://www.technorati.com/tag/search" rel="tag">search</a>, <a href="http://www.technorati.com/tag/visualworks" rel="tag">visualworks</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3511416508</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3511416508</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3511416508</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="2924008" type="application/octet-stream" url="http://archive.org/download/St4u217Searchlight/st4u217-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 217: Searchlight</itunes:subtitle>
			<itunes:summary>Searchlight is an (OS X inspired) search tool for VW and ObjectStudio.  Today we'll take a brief look at it.</itunes:summary>
			<itunes:duration>1:31</itunes:duration>
			<itunes:keywords>smalltalk, search, visualworks</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 217: Searchlight</media:title>
				<media:content duration="1:31" fileSize="2924008" type="application/octet-stream" url="http://archive.org/download/St4u217Searchlight/st4u217-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3511416508</wfw:comment>
		</item>
		<item>
			<title>ST 4U 216: Screenshots Within VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_216:_Screenshots_Within_VA_Smalltalk&amp;entry=3511162951</link>
			<category>st4u</category>
			<pubDate>Fri, 06 Apr 2012 11:02:31 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at taking screencaps within the VA Smalltalk environment.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/RbPyLYwhm5s">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u216ScreenshotsWithinVaSmalltalk/st4u216.mp4"><img src="/images/st4u/st4u216-poster.jpg" alt="screencap" title="screencap" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u216ScreenshotsWithinVaSmalltalk/st4u216.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u216ScreenshotsWithinVaSmalltalk/st4u216.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/RbPyLYwhm5s" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll look at a simple feature of VA Smalltalk that is easily overlooked: the ability to take screen captures (full or partial) from within VA.  That includes the ability to focus on individual windows and widgets.  To get started, go to the <em>Options</em> menu in the launcher:</p>

<
<p><img src="/images/vafiles/st4u216-1.png" alt="screencap" title="screencap" /></p>

<p>Select the <em>Screen</em> option.  If you select a region or window, you'll get a (configurable) delay during which you can bring the desired window to the front.  If you decided to capture the entire screen, you should see something like this (using paste into Paint):</p>

<p><img src="/images/vafiles/st4u216-2.png" alt="screen cap" title="screen cap" /></p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/screencap" rel="tag">screencap</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3511162951</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3511162951</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3511162951</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3964465" type="application/octet-stream" url="http://archive.org/download/St4u216ScreenshotsWithinVaSmalltalk/st4u216-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 216: Screenshots Within VA Smalltalk</itunes:subtitle>
			<itunes:summary>You often need to take screencaps when doing software development.  VA has tools for that right in the image</itunes:summary>
			<itunes:duration>2:03</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, screencap</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 216: Screenshots Within VA Smalltalk</media:title>
				<media:content duration="2:03" fileSize="3964465" type="application/octet-stream" url="http://archive.org/download/St4u216ScreenshotsWithinVaSmalltalk/st4u216-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3511162951</wfw:comment>
		</item>
		<item>
			<title>ST 4U 215: Toothpick in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_215:_Toothpick_in_VA_Smalltalk&amp;entry=3510986476</link>
			<category>st4u</category>
			<pubDate>Wed, 04 Apr 2012 10:01:16 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at Toothpick for logging in VA Smalltalk.  It's a lot like log4s, which we covered in other screencasts.  The difference?  Tootpick works across all the major Smalltalk dialects.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/QAHzsf4IEkM">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u215ToothpickInVaSmalltalk/st4u215.mp4"><img src="/images/st4u/st4u215-poster.jpg" alt="Tootpick" title="Toothpick" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u215ToothpickInVaSmalltalk/st4u215.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u215ToothpickInVaSmalltalk/st4u215.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/QAHzsf4IEkM" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll take another look at logging in VA Smalltalk, but we'll use Tootpick - the cross platform logging solution for Smalltalk systems.  First, download the ENVY package from <a href="http://www.metaprog.com/Toothpick/download.html">Metaprog</a>.</p>

<p>Once you have that, import the .dat file into your repository (see <a href="blogView?entry=3485410942">this screencast</a> for an example of doing that).  Then load SUnit support - it's an unlisted pre-req for the configuration map:</p>

<p><img src="/images/vafiles/st4u215-1.png" alt="SUnit" title="SUnit" /></p>

<p>Once you have SUnit it, load the Toothpick config map:</p>

<p><img src="/images/vafiles/st4u215-2.png" alt="Toothpick" title="Toothpick" /></p>

<p>Now we can proceed to use the same code that works in other Smalltalks.  First, set up the logger (we'll use a Transcript logger here), and start the logging system:</p>


<p>
<pre>

"create a logger"
logger1 := TranscriptLogger new
			name: 'My first Logger'.

"where do logging events go"
logger1 format: SimpleLoggingFormatter defaultFormat.

"logging policy"
logger1 policy: (LoggingPolicy category: #debug level: #debug).

"register the logger"
(LoggingMultiplexer current)
	addLogger: logger1.

"Start the loggers"
(LoggingMultiplexer current) startAllLoggers.

</pre>
</p>



<p>That sets up the logger.  Now we'll use it:</p>

<p>
<pre>

LoggingEvent 
	category: #debug 
	level: #warn 
	message: 'using obsolete protocol'.


</pre>
</p>

<p>A quick look at the Transcript shows that it works as we intended:</p>

<p><img src="/images/vafiles/st4u215-3.png" alt="Toothpick" title="Toothpick" /></p>


<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/logging" rel="tag">logging</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3510986476</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3510986476</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3510986476</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3680673" type="application/octet-stream" url="http://archive.org/download/St4u215ToothpickInVaSmalltalk/st4u215-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 215: Toothpick in VA Smalltalk</itunes:subtitle>
			<itunes:summary>We took a look at Toothpick for logging in VW and Pharo recently; today we'll have a look at how to use it in VA Smalltalk</itunes:summary>
			<itunes:duration>2:08</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, logging</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 215: Toothpick in VA Smalltalk</media:title>
				<media:content duration="2:08" fileSize="3680673" type="application/octet-stream" url="http://archive.org/download/St4u215ToothpickInVaSmalltalk/st4u215-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3510986476</wfw:comment>
		</item>
		<item>
			<title>ST 4U 214: Logging with Toothpick</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_214:_Logging_with_Toothpick&amp;entry=3510815311</link>
			<category>st4u</category>
			<pubDate>Mon, 02 Apr 2012 10:28:31 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at logging with Toothpick in VisualWorks and Pharo (the code is available for VA, and Dolphin as well - and the VW code works in ObjectStudio, while the Squeak code is what I used in Pharo).  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/5BSy07EkasM">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u214LoggingWithToothpick/st4u214.mp4"><img src="/images/st4u/st4u214-poster.jpg" alt="Logging" title="Logging" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u214LoggingWithToothpick/st4u214.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u214LoggingWithToothpick/st4u214.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/5BSy07EkasM" frameborder="0" allowfullscreen></iframe>
</p>


<p>The logging code used in the screencast, which you can find documented at <a href="http://www.metaprog.com/Toothpick">metaprog</a>:</p>

<p>
<pre>

"create a logger"
logger1 := TranscriptLogger new
			name: 'My first Logger'.

"where do logging events go"
logger1 format: SimpleLoggingFormatter defaultFormat.

"logging policy"
logger1 policy: (LoggingPolicy category: #debug level: #debug).

"register the logger"
(LoggingMultiplexer current)
	addLogger: logger1.

"Start the loggers"
(LoggingMultiplexer current) startAllLoggers.

LoggingEvent 
	category: #debug 
	level: #warn 
	message: 'using obsolete protocol'.

LoggingMultiplexer current stopAllLoggers

</pre>
</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/logging" rel="tag">logging</a>, <a href="http://www.technorati.com/tag/toothpick" rel="tag">toothpick</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3510815311</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3510815311</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3510815311</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="6126431" type="application/octet-stream" url="http://archive.org/download/St4u214LoggingWithToothpick/st4u214-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 214: Logging with Toothpick</itunes:subtitle>
			<itunes:summary>If you want to use logging in your Smalltalk code, take a look at Toothpick.  It works across all the major Smalltalk implementations, and is conceptually similar to log4s.</itunes:summary>
			<itunes:duration>3:14</itunes:duration>
			<itunes:keywords>smalltalk, logging, toothpick</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 214: Logging with Toothpick</media:title>
				<media:content duration="3:14" fileSize="6126431" type="application/octet-stream" url="http://archive.org/download/St4u214LoggingWithToothpick/st4u214-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3510815311</wfw:comment>
		</item>
		<item>
			<title>ST 4U 213: Useful log4s APIs</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_213:_Useful_log4s_APIs&amp;entry=3510562987</link>
			<category>st4u</category>
			<pubDate>Fri, 30 Mar 2012 12:23:07 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> wraps up our look at log4s with an examination of some of the more useful API methods we've brushed over.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/o56QpecjqDA">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u213UsefulLog4sApis/st4u213.mp4"><img src="/images/st4u/st4u213-poster.jpg" alt="log4s" title="log4s" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u213UsefulLog4sApis/st4u213.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u213UsefulLog4sApis/st4u213.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/o56QpecjqDA" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll look at some of the useful API methods for log4s that we've brushed over in the last few screencasts.  To get started, we'll add a Transcript appender to the root logger (which was set up in the ini file):</p>


<p>
<pre>

"logging apis"
logger := EsLogManager getLogger: 'root'.

"Add a transcript appender programmatically, but set at a higher level"
level := EsLogManager getLevel: 'Error'.
pattern := EsPatternLayout new: '%6B4e{ISO8601}: [%level] %message'.
transcriptAppender := EsTranscriptAppender level: level layout:  pattern.
logger addAppender: transcriptAppender.


</pre>
</p>

<p>One of the things you can do is ask a logger for all of the appenders it has:</p>

<p>
<pre>

"get all appenders"
logger allAppenders.

</pre>
</p>

<p>Which gives us this, if we inspect that line of code:</p>


<p><img src="/images/vafiles/st4u213-1.png" alt="all appenders" title="all appenders" /></p>



<p>You can also get a specific appender by name:</p>


<p>
<pre>

"get the transcript appender"
logger getAppender: 'Transcript'


</pre>
</p>



<p>If we inspect that, we'll see the following:</p>

<p><img src="/images/vafiles/st4u213-2.png" alt="appender" title="appender" /></p>



<p>Next we'll remove the Transcript appender.  Note that we need to send the appender, not the name, as the argument. The VA 8.5 document is not clear about that:</p>

<p>
<pre>

"remove the Transcript appender"
logger removeAppender: transcriptAppender.

</pre>
</p>

<p>Now inspect the all appenders API again, and you should see:</p>

<p><img src="/images/vafiles/st4u213-3.png" alt="appender" title="appender" /></p>

<p>Note that we're back where we started  just the appender specified in the ini file.  Finally, you can remove all appenders:</p>

<p>
<pre>

"remove all"
logger removeAllAppenders.

</pre>
</p>

<p>And inspecting the all appenders api yields:</p>

<p><img src="/images/vafiles/st4u213-4.png" alt="appender" title="appender" /></p>

<p>And that about wraps it up for log4s.  You should definitely peruse the documentation for more information</p>


<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/log4s" rel="tag">log4s</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3510562987</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3510562987</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3510562987</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3360554" type="application/octet-stream" url="http://archive.org/download/St4u213UsefulLog4sApis/st4u213-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 213: Useful log4s APIs</itunes:subtitle>
			<itunes:summary>Today we'll wrap up our look at log4s in VA Smalltalk with an examination of some of the useful APIs that we've brushed over in the other screencasts on log4s</itunes:summary>
			<itunes:duration>1:51</itunes:duration>
			<itunes:keywords>smalltalk, log4s, va smalltalk</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 213: Useful log4s APIs</media:title>
				<media:content duration="1:51" fileSize="3360554" type="application/octet-stream" url="http://archive.org/download/St4u213UsefulLog4sApis/st4u213-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3510562987</wfw:comment>
		</item>
		<item>
			<title>ST 4U 212: Customizing log4s output</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_212:_Customizing_log4s_output&amp;entry=3510384029</link>
			<category>st4u</category>
			<pubDate>Wed, 28 Mar 2012 10:40:29 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at how you can customize the output of log4s data via the built in pattern specifiers - and the support code that you can implement to make use of it.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/EH8H5bR-kDQ">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u212CustomizingLog4sOutput/st4u212.mp4"><img src="/images/st4u/st4u212-poster.jpg" alt="Logging" title="Logging" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u212CustomizingLog4sOutput/st4u212.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u212CustomizingLog4sOutput/st4u212.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/EH8H5bR-kDQ" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll take look at customizing your logging (in log4s) via the pattern strings used when setting up a logger.  First off, you should look at the documentation, where you'll find this page, explaining the various options:</p>

<p><img src="/images/vafiles/st4u212-1.png" alt="logging" title="logging" /></p>

<p>What we'll do today is set up some object specific logging based on the API supported by our objects.  We'll create two simple classes which respond to the same method - #addOne, adding one to a counter.  One will implement #printOn: (customizing #printString), the other will implement #printLog4s.  To get that all to show up, we'll use the %object specifier in the log setup:</p>


<p>
<pre>

level := EsLogManager getLevel: 'All'.
pattern := EsPatternLayout new: '%date{ISO8601}: [%level]  [%object] %message:'.
transcriptAppender := EsTranscriptAppender level: level layout:  pattern.
logger addAppender: transcriptAppender.

</pre>
</p>



<p>If your object implements #printLog4s, that will get used instead of #printString.  Here's what the code for Adder1 and Adder2 (the two classes) looks like:</p>

<p>
<pre>

Adder1:

printOn: stream
	super printOn: stream.
	stream nextPutAll: ' <', count printString, '>'

Adder2:

printLog4s
	^'LOGGING:  <', count printString, '>'

</pre>
</p>

<p>Now we'll execute the following:</p>

<p>
<pre>

"with logging on, go ahead and watch two different results"
adder1 := Adder1 new.
adder2 := Adder2 new.

adder1 addOne.
adder2 addOne.


</pre>
</p>

<p>And this is what we see in the Transcript:</p>

<p>
<pre>

2012-03-28 09:59:22,031: [WARN]  [an Adder1 <1>] Added one:
2012-03-28 09:59:28,937: [WARN]  [LOGGING:  <1>] Added one:


</pre>
</p>

<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/logging" rel="tag">logging</a></p><!-- technorati tags end -->
</div>  ]]></description>
			<guid isPermaLink="false">3510384029</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3510384029</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3510384029</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4439160" type="application/octet-stream" url="http://archive.org/download/St4u212CustomizingLog4sOutput/st4u212-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 212: Customizing log4s output</itunes:subtitle>
			<itunes:summary>Today's screencast looks at how you can customize the output of log4s data via the built in pattern specifiers - and the support code that you can implement to make use of it.</itunes:summary>
			<itunes:duration>2:17</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, logging</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 212: Customizing log4s output</media:title>
				<media:content duration="2:17" fileSize="4439160" type="application/octet-stream" url="http://archive.org/download/St4u212CustomizingLog4sOutput/st4u212-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3510384029</wfw:comment>
		</item>
		<item>
			<title>ST 4U 211:  Inspectors and Workspaces in VW</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_211:__Inspectors_and_Workspaces_in_VW&amp;entry=3510208776</link>
			<category>st4u</category>
			<pubDate>Mon, 26 Mar 2012 09:59:36 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at the ability to use drag/drop between inspectors and workspaces in VisualWorks (or ObjectStudio).  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/ICAHqqGupsw">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u211InspectorsAndWorkspacesInVw/st4u211.mp4"><img src="/images/st4u/st4u211-poster.jpg" alt="Workspace" title="Workspace" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u211InspectorsAndWorkspacesInVw/st4u211.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u211InspectorsAndWorkspacesInVw/st4u211.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/ICAHqqGupsw" frameborder="0" allowfullscreen></iframe>
</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/workspace" rel="tag">workspace</a>, <a href="http://www.technorati.com/tag/inspector" rel="tag">inspector</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3510208776</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3510208776</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3510208776</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="2290873" type="application/octet-stream" url="http://archive.org/download/St4u211InspectorsAndWorkspacesInVw/st4u211-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 211:  Inspectors and Workspaces in VW</itunes:subtitle>
			<itunes:summary>Many people don't realize that in VisualWorks (and ObjectStudio, for that matter), you can drag objects from an inspector over to a workspace - which makes it easy to experiment with a "live" object.</itunes:summary>
			<itunes:duration>1:23</itunes:duration>
			<itunes:keywords>smalltalk, inspector, workspace, visualworks</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 211:  Inspectors and Workspaces in VW</media:title>
				<media:content duration="1:23" fileSize="2290873" type="application/octet-stream" url="http://archive.org/download/St4u211InspectorsAndWorkspacesInVw/st4u211-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3510208776</wfw:comment>
		</item>
		<item>
			<title>ST 4U 210:  Filtering Logs by Level</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_210:__Filtering_Logs_by_Level&amp;entry=3509947999</link>
			<category>st4u</category>
			<pubDate>Fri, 23 Mar 2012 09:33:19 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at filtering logging events in log4s using logging levels.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/PRTEkzEA1fE">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://archive.org/download/St4u210FilteringLogsByLevel/st4u210.mp4"><img src="/images/st4u/st4u210-poster.jpg" alt="Logging" title="Logging" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://archive.org/download/St4u210FilteringLogsByLevel/st4u210.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://archive.org/download/St4u210FilteringLogsByLevel/st4u210.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/PRTEkzEA1fE" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll take a closer look at logging levels in log4s.  To quote the documentation in VA Smalltalk:</p>

<blockquote>
The concept of levels is central to log4s. A loggingEvent will be logged by an Appender if the level of the loggingEvent is greater than or equal to the level of the Appender. Both LoggingEvents and Appenders have levels. Log4s has seven predefined levels which are implemented as EsLevel class variables.
</blockquote>

<p>There are 7 levels to logging - in order from the lowest (everything gets logged) to the highest (nothing gets logged), they are: All, Debug, Info, Warn, Error, Fatal, Off.  So if you set the level for an appender to "Error", and then send a "Warn" level message, it will not appear in that appender's stream.  For example - recall that we've set up the root logger with a file appender:</p>


<p>
<pre>

[log4s]
debugEnabled=true
quietMode=false
globalLevel=All
dailyRollingFileAppender =(fileAppender, root, vaLog.log, false, Info, EsPatternLayout,
 '%6B4e{ISO8601}: [%level] %message', true, topOfDay )


</pre>
</p>

<p>That will log everything to a file.  Let's set up a new appender to the Transcript, but set it up at the "Error" level - meaning, it will ignore all logging events under that:</p>

<p>
<pre>

"Add a transcript appender programmatically, but set at a higher level"
level := EsLogManager getLevel: 'Error'.
pattern := EsPatternLayout new: '%6B4e{ISO8601}: [%level] %message'.
transcriptAppender := EsTranscriptAppender level: level layout:  pattern.
logger addAppender: transcriptAppender.

</pre>
</p>

<p>Now we have two appenders for the default logger - the file appender will get every logging event, while the Transcript will only see things at level "Error" and above.  To demonstrate, let's send a warning event:</p>

<p>
<pre>

EsLogManager warn: 'This is a warning!'.


</pre>
</p>

<p>The File log has that, while the Transcript is blank:</p>

<p><img src="/images/vafiles/st4u210-1.png" alt="Logging" title="Logging" /></p>

<p>Now let's send an error level event, and look again:</p>

<p>
<pre>

EsLogManager error: 'This is an Error!'.

</pre>
</p>

<p><img src="/images/vafiles/st4u210-2.png" alt="Logging" title="Logging" /></p>

<p>Notice that this time, the event hit both logs - the file appender gets everything, while the Transcript appender got the higher level event only.  Next time, we'll get into filtering and the print format.</p>


<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/logging" rel="tag">logging</a>, <a href="http://www.technorati.com/tag/log4s" rel="tag">log4s</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3509947999</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3509947999</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3509947999</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="5721668" type="application/octet-stream" url="http://archive.org/download/St4u210FilteringLogsByLevel/st4u210-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 210:  Filtering Logs by Level</itunes:subtitle>
			<itunes:summary>Today we'll look at coarse grained filtering in log4s - specifying different logging levels for appenders on the same logger</itunes:summary>
			<itunes:duration>3:18</itunes:duration>
			<itunes:keywords>smalltalk, logging, log4s</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 210:  Filtering Logs by Level</media:title>
				<media:content duration="3:18" fileSize="5721668" type="application/octet-stream" url="http://archive.org/download/St4u210FilteringLogsByLevel/st4u210-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3509947999</wfw:comment>
		</item>
		<item>
			<title>ST 4U 209: Creating a new Logger with log4s</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_209:_Creating_a_new_Logger_with_log4s&amp;entry=3509769188</link>
			<category>st4u</category>
			<pubDate>Wed, 21 Mar 2012 07:53:08 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> delves deeper into log4s, looking at how to create a new logger in code (as opposed to in the ini file).  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/bq2q5wSoZnc">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://www.archive.org/download/St4u209CreatingANewLoggerWithLog4s/st4u209.mp4"><img src="/images/st4u/st4u209-poster.jpg" alt="log4s" title="log4s" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://www.archive.org/download/St4u209CreatingANewLoggerWithLog4s/st4u209.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://www.archive.org/download/St4u209CreatingANewLoggerWithLog4s/st4u209.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/bq2q5wSoZnc" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll create a new logger in VA Smalltalk, programmatically.  Recall that the way we set up the standard (root) logger to write to a file was via the ini file for the VA image:</p>

<p>
<pre>

[log4s]
debugEnabled=true
quietMode=false
globalLevel=All
dailyRollingFileAppender =(fileAppender, root, vaLog.log, false, Info, EsPatternLayout,
 '%6B4e{ISO8601}: [%level] %message', true, topOfDay )


</pre>
</p>

What we need to do today is create a brand new logger:</p>

<p>
<pre>

"create a new logger using the Transcript"
myLogger := EsLogManager createLogger: 'myLogger'.
level := EsLogManager getLevel: 'All'.
pattern := EsPatternLayout new: '%6B4e{ISO8601}: [%level] %message'.
transcriptAppender := EsTranscriptAppender level: level layout: pattern.
myLogger addAppender: transcriptAppender.

</pre>
</p>

<p>That creates a brand new logger using the name 'myLogger' - to use it, we now need to specify that specifically (without being specific, we get the root logger):</p>

<p>
<pre>

"use the root logger"
EsLogManager warn: 'This is a warning!'.

"use the new logger"
(EsLogManager getLogger: 'myLogger') warn: 'This is another warning!'.


</pre>
</p>

<p>The first warning goes to the file logger set up on root; the second one goes to the Transcript using the new logger.</p>



<p>We'll delve more into the settings and filtering options for log4s in a future screencast</p>




<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/logging" rel="tag">logging</a>, <a href="http://www.technorati.com/tag/log4s" rel="tag">log4s</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3509769188</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3509769188</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3509769188</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4192505" type="application/octet-stream" url="http://www.archive.org/download/St4u209CreatingANewLoggerWithLog4s/st4u209-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 209: Creating a new Logger with log4s</itunes:subtitle>
			<itunes:summary>Need to have separate loggers to track different applications/parts of applications?  Log4s makes that easy</itunes:summary>
			<itunes:duration>2:18</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, logging</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 209: Creating a new Logger with log4s</media:title>
				<media:content duration="2:18" fileSize="4192505" type="application/octet-stream" url="http://www.archive.org/download/St4u209CreatingANewLoggerWithLog4s/st4u209-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3509769188</wfw:comment>
		</item>
		<item>
			<title>ST 4U 208: Pastell - XPath Type Capabilities in Pharo</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_208:_Pastell_-_XPath_Type_Capabilities_in_Pharo&amp;entry=3509598100</link>
			<category>st4u</category>
			<pubDate>Mon, 19 Mar 2012 08:21:40 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at using <a href="http://astares.blogspot.com/2010/01/pharosqueak-and-xml.html">Pastell</a> (for XML) in Pharo Smalltalk.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/6fUtdQ0-5yA">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://www.archive.org/download/St4u208Pastell-XpathTypeCapabilitiesInPharo/st4u208.mp4"><img src="/images/st4u/st4u208-poster.jpg" alt="XML" title="XML" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://www.archive.org/download/St4u208Pastell-XpathTypeCapabilitiesInPharo/st4u208.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://www.archive.org/download/St4u208Pastell-XpathTypeCapabilitiesInPharo/st4u208.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/6fUtdQ0-5yA" frameborder="0" allowfullscreen></iframe>
</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/xml" rel="tag">xml</a>, <a href="http://www.technorati.com/tag/pharo" rel="tag">pharo</a>, <a href="http://www.technorati.com/tag/pastell" rel="tag">pastell</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3509598100</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3509598100</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3509598100</pingback:target>
			<includedComments:comment-collection>
				<includedComments:comment>
					<includedComments:guid>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_208:_Pastell_-_XPath_Type_Capabilities_in_Pharo&amp;entry=3509598100</includedComments:guid>
					<includedComments:puid>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_208:_Pastell_-_XPath_Type_Capabilities_in_Pharo&amp;entry=3509598100</includedComments:puid>
					<includedComments:author>gcorriga</includedComments:author>
					<includedComments:pubDate>2012-03-19T13:14:13-04:00</includedComments:pubDate>
					<includedComments:content>&lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;
&lt;p&gt;Nice to see that a Sunday afternoon hack is still alive and kicking five years later.&lt;/p&gt;
&lt;/div&gt;</includedComments:content>
					<includedComments:title>Re: ST 4U 208: Pastell - XPath Type Capabilities in Pharo</includedComments:title>
				</includedComments:comment>
			</includedComments:comment-collection>
			<enclosure length="2318891" type="application/octet-stream" url="http://www.archive.org/download/St4u208Pastell-XpathTypeCapabilitiesInPharo/st4u208-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 208: Pastell - XPath Type Capabilities in Pharo</itunes:subtitle>
			<itunes:summary>Need to dig deeper into an XML document, but don't want to get bogged down at the element and node level?  If you use Pharo, check out Pastell</itunes:summary>
			<itunes:duration>1:23</itunes:duration>
			<itunes:keywords>smalltalk, pharo, xml, pastell</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 208: Pastell - XPath Type Capabilities in Pharo</media:title>
				<media:content duration="1:23" fileSize="2318891" type="application/octet-stream" url="http://www.archive.org/download/St4u208Pastell-XpathTypeCapabilitiesInPharo/st4u208-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3509598100</wfw:comment>
		</item>
		<item>
			<title>ST 4U 207: Using log4s in VA Smalltalk</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_207:_Using_log4s_in_VA_Smalltalk&amp;entry=3509343689</link>
			<category>st4u</category>
			<pubDate>Fri, 16 Mar 2012 09:41:29 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> continues our examination fo log4s, setting up a new logging channel (called an appender in the framework).  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/J_fjYVbLaN0">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://www.archive.org/download/St4u207UsingLog4sInVaSmalltalk/st4u207.mp4"><img src="/images/st4u/st4u207-poster.jpg" alt="Logging" title="Logging" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://www.archive.org/download/St4u207UsingLog4sInVaSmalltalk/st4u207.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://www.archive.org/download/St4u207UsingLog4sInVaSmalltalk/st4u207.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/J_fjYVbLaN0" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll add a new logging stream (called an appender in the framework) using log4s.  The same information gets logged to all streams for a given logger; we'll look at how to add new loggers in another screencast.  First, recall how we specified the root level logger in the VA ini file:</p>

<p>
<pre>

[log4s]
debugEnabled=true
quietMode=false
globalLevel=All
dailyRollingFileAppender =(fileAppender, root, vaLog.log, false, Info, EsPatternLayout,
 '%6B4e{ISO8601}: [%level] %message', true, topOfDay )


</pre>
</p>

Now, if we send a logging event, as we do below, it drops out to our specified log file:</p>

<p>
<pre>

"simple log event"
EsLogManager warn: 'This is a warning, beware!'

</pre>
</p>

<p>What if we wanted another stream, on the Transcript?  We could specify that in the ini file, or in code - as follows:</p>

<p>
<pre>

"Add a transcript appender programmatically"
level := EsLogManager getLevel: 'All'.
pattern := EsPatternLayout new: '%6B4e{ISO8601}: [%level] %message'.
transcriptAppender := EsTranscriptAppender level: level layout:  pattern.
logger addAppender: transcriptAppender.

</pre>
</p>

<p>Now, if we send that logging event again, it'll not only go to the file, but also to the Transcript:</p>



<p><img src="/images/vafiles/st4u207-1.png" alt="Logging" title="Logging" /></p>

<p>We'll get into setting up new loggers in a future screencast</p>




<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>

<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/logging" rel="tag">logging</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3509343689</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3509343689</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3509343689</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="3645789" type="application/octet-stream" url="http://www.archive.org/download/St4u207UsingLog4sInVaSmalltalk/st4u207-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 207: Using log4s in VA Smalltalk</itunes:subtitle>
			<itunes:summary>Today we'll continue with log4s, looking at how to set up a new appender (logging stream) on an already configured logger.</itunes:summary>
			<itunes:duration>2:03</itunes:duration>
			<itunes:keywords>smalltalk, va smalltalk, logging</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 207: Using log4s in VA Smalltalk</media:title>
				<media:content duration="2:03" fileSize="3645789" type="application/octet-stream" url="http://www.archive.org/download/St4u207UsingLog4sInVaSmalltalk/st4u207-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3509343689</wfw:comment>
		</item>
		<item>
			<title>ST 4U 206: Introducing Log4s</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_206:_Introducing_Log4s&amp;entry=3509175702</link>
			<category>st4u</category>
			<pubDate>Wed, 14 Mar 2012 11:01:42 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at log4s (a logging framework) in VA Smalltalk.  Today we just scratch the surface; there will be more screencasts on this topic.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/fNy7RHKzPpg">navigate directly to YouTube</a>.  To watch now, click on the image below:</p>

<p>
<a href="http://www.archive.org/download/St4u204ChangingTheFontsInVaSmalltalk/st4u204.mp4"><img src="/images/st4u/st4u206-poster.jpg" alt="log4s" title="log4s" />.</a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://www.archive.org/download/St4u206IntroducingLog4s/st4u206.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://www.archive.org/download/St4u206IntroducingLog4s/st4u206.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/fNy7RHKzPpg" frameborder="0" allowfullscreen></iframe>

</p>

<a name="vawalk"></a>
<hr/>
<p>Today we'll look at the logging framework that ships with VA Smalltalk - log4s (A Smalltalk port of the well known log4J package).  It's already in your image, so there's no need to load it from ENVY.  There are a couple of different ways to get started, but today we'll look at setting it up via the ini file.  Every VA image has a corresponding (same base name) ini file - you'll want to append a new &quot;stanza&quot; to it.  Here we are setting up a basic file logger, using the default root level logger.  You can have multiple logging streams (each filtered separately) on a single logger; today we'll just look at a simple file logger.  Here's the way we define that in the ini file:</p>

<p>
<pre>

[log4s]
debugEnabled=true
quietMode=false
globalLevel=All
dailyRollingFileAppender =(fileAppender, root, vaLog.log, false, Info, EsPatternLayout,
 '%6B4e{ISO8601}: [%level] %message', true, topOfDay )


</pre>
</p>

What that sets up is a file logger off the root (technically, a new appender - each logger can have any number of appenders associated with it).  When you log something, it will appear in that log file (we specified vaLog.log above).  The pattern specified how the log entry appears; the VA documentation goes through in great detail how you can customize that.  To log a warning, you can do something like this:</p>

<p>
<pre>

"simple log event"
EsLogManager warn: 'This is a warning, beware!'

</pre>
</p>

<p>One caveat - the doc talks about class LogManager, while it's actually EsLogManager.  The output for what we did above?</p>


<p><img src="/images/vafiles/st4u206-1.png" alt="Logging" title="Logging" /></p>

<p>We'll get into filtering, programmatic setup and more in the future screencasts</p>




<p>Need more help?  There's a <a href="http://www.jarober.com/blog/st4u.ssp">screencast for other topics like this</a> which you may want to watch.  Questions?  Try the "Chat with James" Google gadget over in the sidebar.</p>



<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/va smalltalk" rel="tag">va smalltalk</a>, <a href="http://www.technorati.com/tag/logging" rel="tag">logging</a>, <a href="http://www.technorati.com/tag/log4s" rel="tag">log4s</a></p><!-- technorati tags end -->
</div>]]></description>
			<guid isPermaLink="false">3509175702</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3509175702</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3509175702</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4534045" type="application/octet-stream" url="http://www.archive.org/download/St4u206IntroducingLog4s/st4u206-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 206: Introducing Log4s</itunes:subtitle>
			<itunes:summary>Today we'll start looking at log4s (a logging framework) in VA Smalltalk</itunes:summary>
			<itunes:duration>2:51</itunes:duration>
			<itunes:keywords>smalltalk, log4s, va smalltalk</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 206: Introducing Log4s</media:title>
				<media:content duration="2:51" fileSize="4534045" type="application/octet-stream" url="http://www.archive.org/download/St4u206IntroducingLog4s/st4u206-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3509175702</wfw:comment>
		</item>
		<item>
			<title>ST 4U 205: A Pharo Launcher</title>
			<link>http://www.jarober.com/blog/blogView?showComments=true&amp;printTitle=ST_4U_205:_A_Pharo_Launcher&amp;entry=3509004393</link>
			<category>st4u</category>
			<pubDate>Mon, 12 Mar 2012 11:26:33 GMT</pubDate>
			<description><![CDATA[<div xmlns="http://www.w3.org/1999/xhtml">

<p>Today's <a href="http://www.jarober.com/blog/st4u.ssp" title="Smalltalk 4 You">Smalltalk 4 You</a> looks at the Pharo Launcher in Pharo - it works somewhat like the project launcher for VisualWorks, but it's specific to the Mac (and OS X Lion at that).  You can find it in the app store.  If you have trouble viewing it here in the browser, you can also <a href="http://youtu.be/zzsDMB-Srj4">navigate directly to YouTube</a>.    To watch now, click on the image below:</p>

<p>
<a href="http://www.archive.org/download/St4u205APharoLauncher/st4u205.mp4"><img src="/images/st4u/st4u205-poster.jpg" alt="Pharo Launcher" title="Pharo Launcher" /></a>
</p>


<p>If you have trouble viewing that directly, you can <a href="http://www.archive.org/download/St4u205APharoLauncher/st4u205.mp4">click here</a> to download the video directly.  If you need the video in a Windows Media format, then <a href="http://www.archive.org/download/St4u205APharoLauncher/st4u205.wmv">download that here</a>. </p>



<p>You can also watch it on YouTube:</p>

<p>
<iframe width="560" height="315" src="http://www.youtube.com/embed/zzsDMB-Srj4" frameborder="0" allowfullscreen></iframe>
</p>


<!-- technorati tags start --><p style="text-align:right;font-size:10px;">Technorati Tags: 
<a href="http://www.technorati.com/tag/smalltalk" rel="tag">smalltalk</a>, <a href="http://www.technorati.com/tag/pharo" rel="tag">pharo</a>, <a href="http://www.technorati.com/tag/launcher" rel="tag">launcher</a></p><!-- technorati tags end -->
</div>
]]></description>
			<guid isPermaLink="false">3509004393</guid>
			<pingback:server>http://www.jarober.com/blog/servlet/CommentAPIPBServlet?guid=3509004393</pingback:server>
			<pingback:target>http://www.jarober.com/blog/blogView?guid=3509004393</pingback:target>
			<includedComments:comment-collection></includedComments:comment-collection>
			<enclosure length="4446651" type="application/octet-stream" url="http://www.archive.org/download/St4u205APharoLauncher/st4u205-iPhone.m4v"></enclosure>
			<itunes:explicit>no</itunes:explicit>
			<itunes:author>James Robertson</itunes:author>
			<itunes:subtitle>ST 4U 205: A Pharo Launcher</itunes:subtitle>
			<itunes:summary>There's an image launcher for VisualWorks, and now there's also one for Pharo - at least on the Mac.  Today we'll have a look at it.</itunes:summary>
			<itunes:duration>2:17</itunes:duration>
			<itunes:keywords>smalltalk, pharo, launcher</itunes:keywords>
			<media:group>
				<media:rating>nonadult</media:rating>
				<media:credit role="author">James Robertson</media:credit>
				<media:title>ST 4U 205: A Pharo Launcher</media:title>
				<media:content duration="2:17" fileSize="4446651" type="application/octet-stream" url="http://www.archive.org/download/St4u205APharoLauncher/st4u205-iPhone.m4v"></media:content>
			</media:group>
			<wfw:comment>http://www.jarober.com/blog/servlet/CommentAPIServlet?guid=3509004393</wfw:comment>
		</item>
	</channel>
</rss>

