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

<channel>
	<title>The Boschmans Account</title>
	<atom:link href="http://www.boschmans.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.boschmans.net</link>
	<description>A collection of interests and happenings...</description>
	<lastBuildDate>Sun, 07 Mar 2010 21:57:15 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Using CherryPy for webform authentication</title>
		<link>http://www.boschmans.net/2010/03/07/using-cherrypy-for-webform-authentication/</link>
		<comments>http://www.boschmans.net/2010/03/07/using-cherrypy-for-webform-authentication/#comments</comments>
		<pubDate>Sun, 07 Mar 2010 21:48:57 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[cherrypy]]></category>
		<category><![CDATA[python]]></category>
		<category><![CDATA[website]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=965</guid>
		<description><![CDATA[If you are using CherryPy, I can recommend the webform-based authentication that Arnar Birgisson wrote for ease of use and extensability.
After trying out the included authentication models with CherryPy (I&#8217;m using 3.1.2, the last stable version at the moment of writing), I was disappointed in the results. Then I stumbled over a recommandation from someone [...]]]></description>
			<content:encoded><![CDATA[<p>If you are using CherryPy, I can recommend the webform-based authentication that <a title="Arnar Birgisson" href="http://www.hvergi.net/arnar/" target="_blank">Arnar Birgisson</a> wrote for ease of use and extensability.</p>
<p>After trying out the included authentication models with CherryPy (I&#8217;m using 3.1.2, the last stable version at the moment of writing), I was disappointed in the results. Then I stumbled over a recommandation from someone on <a title="Nabble Forum System" href="http://old.nabble.com/" target="_blank">Nabble</a>, a web-based programmar&#8217;s discussion forum, which pointed to the following wiki page on the CherryPy site:</p>
<p><a title="CherryPy Authentication and Access restrictions" href="http://tools.cherrypy.org/wiki/AuthenticationAndAccessRestrictions" target="_blank">http://tools.cherrypy.org/wiki/AuthenticationAndAccessRestrictions</a></p>
<p>The complete program code plus examples are on the page and are well explained.</p>
<p>You can have a skeleton login system (using a hardcoded dictionary) up and running in literally half an hour !</p>
<ul>
<li> Just copy/paste the code on the page and save it as auth.py in your cherrypy script dir.</li>
<li>Add the hardcoded dictionary containing username and passwords to it (or script the db access, see the example included)</li>
<li>Put &#8216;require()&#8217; everywhere on your cherrypy pages that need to have login protection &#8211; additionally, you can also have roles so that only admins can access certain pages.</li>
</ul>
<p>Early last week I replaced that hardcoded dictionary and built the db lookup query for the login. Once that was working, I added a &#8216;my profile&#8217; page to the application I&#8217;m working on.  Then I thought it would be nice for the admin to have a &#8216;create user&#8217; form in the admin section to add users. Done that as well, using the jquery-ui to create tabs and seperate content in the admin section.</p>
<p>All in all, a nice week of nice work.</p>
<p>I&#8217;m starting to think this might make it&#8217;s way to my hosting server one of the coming weeks&#8230;  although I need to do some more work on showing the user only his keywords and not all the keywords, as well as doing something with the keywords to use them better.</p>
<p>Oh and one more thing: this works better under SSL than in the clear http: sky !</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/03/07/using-cherrypy-for-webform-authentication/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Startup ideas I&#8217;m having.</title>
		<link>http://www.boschmans.net/2010/02/28/startup-ideas-im-having/</link>
		<comments>http://www.boschmans.net/2010/02/28/startup-ideas-im-having/#comments</comments>
		<pubDate>Sun, 28 Feb 2010 18:45:09 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Blog News]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[startup]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=959</guid>
		<description><![CDATA[The last few months I&#8217;ve been working on various projects, but I haven&#8217;t been blogging about them, mostly because I usually only post about either something amusing I found on the Interwebs or because whatever programming problems I&#8217;ve just solved merit some attention and I couldn&#8217;t readily find a solution for.
This blog has grown from [...]]]></description>
			<content:encoded><![CDATA[<p>The last few months I&#8217;ve been working on various projects, but I haven&#8217;t been blogging about them, mostly because I usually only post about either something amusing I found on the Interwebs or because whatever programming problems I&#8217;ve just solved merit some attention and I couldn&#8217;t readily find a solution for.</p>
<p>This blog has grown from being just a personal blog to one where lately quite a lot of the posts concern programming issues, interspersed with only some personal posts.</p>
<p>Currently I&#8217;m following quite a few entrepreneurs out there, and some of these blogs by entrepreneurs talk about start-ups and in the next blog post about a technical issue they had to deal with or solve. I quite like that combination. I think it interesting enough that I will start to blog about my quest  to launch a start-up, and how I arrived at that idea.</p>
<p><strong>So why I am looking to set up a start-up ?</strong></p>
<p>Currently I&#8217;m working full-time as an Online Sales Manager, but more and more the technical side of things is being done by other people in other departments, less and less by me. Being somebody who loves IT and all the things around it, that leaves me with a serious technical itch to scratch. As pressure at work is sometimes heavy, I&#8217;ve started programming again during the evenings as a stress-release.  I figure I might &#8216;do&#8217; something with this programming. Also, this answers my need to do &#8216;useful&#8217; stuff.</p>
<p>In a large organization a lot of what you do are meetings, meetings, meetings to decide what to do. Then you make decisions which are challenged by committees. Finally after days or weeks or months of wrangling a compromise is reached. And then finally you or someone else can &#8216;do&#8217; the necessary work. It&#8217;s not exactly instant coffee, if you know what I mean. A start-up of one means that I can focus on what I want and do something just about immediately (ahem. We&#8217;ll see).</p>
<p>So I&#8217;m thinking about setting up a start-up where I can scratch that programming itch and (perhaps) make some pocket money doing that.</p>
<p><strong>I&#8217;ve done some soul-searching&#8230;</strong></p>
<p>The questions I&#8217;ve been asking myself these last 6 months have been  various :</p>
<ul>
<li>What do I want to achieve ?</li>
<li>What do I really want to do ?</li>
<li>Just how far do I want to go with this ?</li>
<li>Do I really want or need a startup ?</li>
<li>What sort of startup ?</li>
<li>And what are my business ideas ?</li>
<li>Do I want to sell something ?</li>
<li>What exactly ?</li>
<li>How much time am I willing to spend on this in time and money ?</li>
<li>And so on&#8230;</li>
</ul>
<p>In the end, I&#8217;ve made a few decisions and come to a conclusion.</p>
<p><strong>Decision: I want do this as an independent.</strong></p>
<p>I&#8217;m going to set myself up as an independent &#8220;on the side&#8221;. Even if I fail, if I don&#8217;t sell anything or things don&#8217;t work out, I want to know what it is to be your own boss, even in a limited way. At least I will have tried, and who knows, I might make make something worthwhile out of it, learn from the experience. I hope to set up something small that can grow over the years.</p>
<p><strong>Decision: Work with the technical strengths I have or can readily acquire.</strong></p>
<p>I have to be realistic. I&#8217;ve made a few websites over the past few years, for me or for  friends of mine, but I&#8217;ve realised that I&#8217;m not a real websitedesigner  and probably never will be one. I&#8217;m no big Photoshop designer that can  create a beautiful design from scratch and cut up the psd in elements  and then code them in html. I love the user experience of a well-designed site, but have no huge creativity when it comes to designing one myself beyond making it functional and error-free.</p>
<p>I&#8217;m more interested in the back-end of the web systems, how things  work. Sure, it gives me satisfaction to spruce up a website with  JavaScript (<a title="JQuery UI" href="http://jqueryui.com/" target="_blank">JQuery-ui</a> rulez because it&#8217;s so easy to make a nice site with it),  putting up the layout and such, but I get an even bigger kick out of  setting up a back-end database and writing the functions that allow you  to search it. Making it work, puzzling out the different ways you can access content. Interfacing it with other content.</p>
<p>A combination of HTML, <a title="JQuery" href="http://jquery.com/" target="_blank">JQuery</a>, <a title="Adobe Flex" href="http://en.wikipedia.org/wiki/Adobe_Flex" target="_blank">Flex</a> and <a title="Python Programming Language" href="http://www.python.org" target="_blank">Python</a>, all of which I know to varying degrees allows me to do both the front-end and the back-end of a website in such a way that the result looks reasonably competent.</p>
<ul>
<li>HTML and JQuery for the front-end</li>
<li>Flex for the display of tables, graphs and complex user interface parts</li>
<li>Python for database connectivity and back-end functions that the front-end parts call.</li>
</ul>
<p>Web hosting providers that provide Python are currently not that much in evidence, but there are <a title="Python Web Hosting" href="http://wiki.python.org/moin/PythonHosting" target="_blank">more and more out there</a>. I myself use <a title="Webfaction" href="http://www.webfaction.com/?affiliate=lexstok" target="_blank">WebFaction</a>, which I can heartily recommend for their quick answers, nice admin interface and reasonable prices.</p>
<p>That is the base functionality, how to get things done. But that is only a means to an end.</p>
<p><strong>Decision: How much time do I want to invest  in it ?</strong></p>
<p>I&#8217;m working a full-time job. Do I want to go all-out, quit my job, or do I want to do this part time ? And am I sure that I can control how much time I invest in it ?</p>
<p>After weighing pro&#8217;s and contras I&#8217;ve decided to do this low-key but long-term. I still want to see my family, not be off to meet some client every evening. I want to build this up over the years.</p>
<p>My main goal, after all, is to scratch my programming itch and make what I create &#8216;useful&#8217; to other people. So no website design, no consultancy (at least not at first), no excel sheet programming. No individual programming stuff for one particular client (exceptions may happen). I am gonna make things more than one person / company can use. Probably sell them as a service or downloadable program.</p>
<p>And as an entrepreneur I respect told me recently: to keep your costs low, make it yourself. Own it. Don&#8217;t sell stuff someone else made if you can create it yourself.</p>
<p>He also told me another golden rule: if you want to do this you  full-time you must sell something people want to buy. This seems to be evident, but it&#8217;s not. In fact, I&#8217;m not sure that I&#8217;m going to be doing that. One more reason to start up on the side, testing the waters so to speak.</p>
<p><strong>Decision: What am I going to sell ?</strong></p>
<p>After deciding on limiting my time used for it, I have narrowed the choices down. So I&#8217;m selling software or services via a little webshop. What sort of software service ? I&#8217;ve decided I&#8217;m going to sell tools, tools that I myself think I need. After all, if I can think of uses for those tools, perhaps other can use them as well ? The first one is a social media tool, to keep track of stuff on Twitter. There are already several tools out, but I am not out to corner the market, I out to learn stuff and see if what I make is useful to other people.</p>
<p><strong>Conclusion: I&#8217;m doing this. This year.</strong></p>
<p>I&#8217;m somebody who needs time to adjust to new stuff. I take my time researching, sometimes too much so. It&#8217;s time to start doing.</p>
<p>I&#8217;ll update on this in the coming months with how it goes&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/02/28/startup-ideas-im-having/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Shit you don&#8217;t know you don&#8217;t know&#8230;</title>
		<link>http://www.boschmans.net/2010/02/21/shit-you-dont-know-you-dont-know/</link>
		<comments>http://www.boschmans.net/2010/02/21/shit-you-dont-know-you-dont-know/#comments</comments>
		<pubDate>Sun, 21 Feb 2010 19:42:59 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Blog News]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=955</guid>
		<description><![CDATA[
Just a pointer to a great blog post about

things you know
things you know you don&#8217;t know
things you don&#8217;t know you know.

Trust me, go and read the blog post, it&#8217;s worth it.
]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boschmans.net/wp-content/uploads/2010/02/tumblr_kxldz31eZQ1qaukck.png"><img class="alignnone size-full wp-image-956" title="things you know and don't know and don't know you don't know" src="http://www.boschmans.net/wp-content/uploads/2010/02/tumblr_kxldz31eZQ1qaukck.png" alt="things you know and don't know and don't know you don't know" width="325" height="387" /></a></p>
<p>Just <a title="No one knows it all" href="http://jangosteve.com/post/380926251/no-one-knows-what-theyre-doing" target="_blank">a pointer</a> to a great blog post about</p>
<ul>
<li>things you know</li>
<li>things you know you don&#8217;t know</li>
<li>things you don&#8217;t know you know.</li>
</ul>
<p>Trust me, go and <a title="Jango Steve - No one knows it all" href="http://jangosteve.com/post/380926251/no-one-knows-what-theyre-doing" target="_blank">read the blog post</a>, it&#8217;s worth it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/02/21/shit-you-dont-know-you-dont-know/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Spoken with Passion</title>
		<link>http://www.boschmans.net/2010/02/11/spoken-with-passion/</link>
		<comments>http://www.boschmans.net/2010/02/11/spoken-with-passion/#comments</comments>
		<pubDate>Thu, 11 Feb 2010 20:45:45 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Blog News]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=951</guid>
		<description><![CDATA[Stephen Fry on (and against) the institution that calls itself the Catholich Church.
The Intelligence&#178; Debate &#8211; Stephen Fry (Unedited)
]]></description>
			<content:encoded><![CDATA[<p>Stephen Fry on (and against) the <b>institution</b> that calls itself the Catholich Church.</p>
<p><object width="480" height="325"><param name="movie" value="http://www.dailymotion.com/swf/xbvr0m"></param><param name="allowFullScreen" value="true"></param><param name="allowScriptAccess" value="always"></param><embed src="http://www.dailymotion.com/swf/xbvr0m" width="480" height="325" allowfullscreen="true" allowscriptaccess="always"></embed></object><br /><b><a href="http://www.dailymotion.com/video/xbvr0m_the-intelligence²-debate-stephen-fr_shortfilms">The Intelligence&sup2; Debate &#8211; Stephen Fry (Unedited)</a></b></p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/02/11/spoken-with-passion/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>400th blog post !</title>
		<link>http://www.boschmans.net/2010/02/06/400th-blog-post/</link>
		<comments>http://www.boschmans.net/2010/02/06/400th-blog-post/#comments</comments>
		<pubDate>Sat, 06 Feb 2010 17:25:57 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Blog News]]></category>
		<category><![CDATA[family]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=948</guid>
		<description><![CDATA[I just noticed that this is my 400th blog post &#8211; I started blogging using Wordpress on Januari 17, 2005 &#8211; more than 5 years ago ! Somewhere on the site there&#8217;s a link to an earlier blog of mine using Bloxsom, but I quickly switched over to Wordpress.
Wordpress has been &#8211; for me &#8211; [...]]]></description>
			<content:encoded><![CDATA[<p>I just noticed that this is my 400th blog post &#8211; I started blogging using Wordpress on Januari 17, 2005 &#8211; more than 5 years ago ! Somewhere on the site there&#8217;s a link to an earlier blog of mine using Bloxsom, but I quickly switched over to Wordpress.</p>
<p><a title="Wordpress" href="http://www.wordpress.com" target="_blank">Wordpress</a> has been &#8211; for me &#8211; the ideal Content Publishing Management (CMS) system.</p>
<p>400 posts means about 6 blog posts per month on average, something which surprised me &#8211; I actually thought it was less.</p>
<p>My first post was about the birthday of Tom, it&#8217;s fitting to put a picture of the family as it is now.</p>
<div id="attachment_949" class="wp-caption alignnone" style="width: 650px"><a href="http://www.boschmans.net/wp-content/uploads/2010/02/P1010623.jpeg"><img class="size-full wp-image-949" title="The Boschmans Family" src="http://www.boschmans.net/wp-content/uploads/2010/02/P1010623.jpeg" alt="A picture of the Boschmans Family" width="640" height="480" /></a><p class="wp-caption-text">A picture of the Boschmans Family end of 2009.</p></div>
<p>Onwards to another 400 blog posts or another 5 years, whichever comes first !</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/02/06/400th-blog-post/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Simple Python threading.Thread example using Queue</title>
		<link>http://www.boschmans.net/2010/02/03/simple-python-threading-thread-example/</link>
		<comments>http://www.boschmans.net/2010/02/03/simple-python-threading-thread-example/#comments</comments>
		<pubDate>Wed, 03 Feb 2010 22:17:23 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=935</guid>
		<description><![CDATA[I managed to write a really simple example of using threads in Python that I hope will give more insight on how to adapt my other programming stuff. And re-use this later on, in case I need to revisit this again it would be handy not to scour the internet again to assemble the bits [...]]]></description>
			<content:encoded><![CDATA[<p>I managed to write a really simple example of using threads in Python that I hope will give more insight on how to adapt my other programming stuff. And re-use this later on, in case I need to revisit this again it would be handy not to scour the internet <em>again</em> to assemble the bits and pieces of threading with Python.</p>
<p>The example below uses 3 threads, and processes 10 pairs of numbers (tuples) that I put in a list.</p>
<div class="codesnip-container" >
<div class="python codesnip" style="font-family:monospace;">
<ol>
<li class="li1">
<div class="de1"><span class="co1"># Our list of work todo</span></div>
</li>
<li class="li1">
<div class="de1">inputlist_ori = <span class="br0">&#91;</span> <span class="br0">&#40;</span><span class="nu0">5</span>,<span class="nu0">5</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">10</span>,<span class="nu0">4</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">78</span>,<span class="nu0">5</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">87</span>,<span class="nu0">2</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">65</span>,<span class="nu0">4</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">10</span>,<span class="nu0">10</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">65</span>,<span class="nu0">2</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">88</span>,<span class="nu0">95</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">44</span>,<span class="nu0">55</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">33</span>,<span class="nu0">3</span><span class="br0">&#41;</span> <span class="br0">&#93;</span></div>
</li>
</ol>
</div>
</div>
<p>Those numbers are divided over those 3 threads by the Queue system.</p>
<p>The Queue system itself is limited to 5 slots, although this could easily be changed to more or less. You will notice in the console print that the message &#8220;Waiting for threads to finish.&#8221; appears after the fifth result, indicating that the queues are being used and the main program has continued on.</p>
<p>After putting everything in the queue system, the program waits for the threads to finish using the .join() function.</p>
<p>All spawned threads keep on being active, running forever, accepting jobs &#8211; that is, until the queue is empty, at which point they shut down.</p>
<p>I based most of my simple example on the examples in the Python threading <a title="Python Threading tutorial" href="http://heather.cs.ucdavis.edu/~matloff/Python/PyThreads.pdf" target="_blank">tutorial</a> (.pdf) work of Norman Matloff and Francis Hsu that I referenced before in <a title="Python Threading information" href="http://www.boschmans.net/2010/01/26/using-threads-in-python/" target="_blank">a previous blog post</a>. However, while their examples undoubtedly do more and are more extensive, they are also more complex. This example is deliberately made as simple as possible so to understand the basic principles of threading and the queue system.</p>
<p>Things I stumbled over:</p>
<ul>
<li>Duh! You spawn the threads <em>before</em> you fill up the queues with stuff todo&#8230;</li>
<li>When printing out things to the console or python shell, things got jumbled because different threads took over from each other &#8211; to solve that I used the threading.Lock().acquire() and threading.Lock().release() to make sure that a thread could finish printing. Not sure if I understand completely all the possibilities this offers.</li>
<li>Still a bit stumped on getting more info, name, etc on the thread that is running at the moment &#8211; haven&#8217;t figured that out yet how to do that.</li>
</ul>
<p>Feel free to comment and ask questions &#8211; if you can improve this program, please let me know !</p>
<div class="codesnip-container" >
<div class="python codesnip" style="font-family:monospace;">
<ol>
<li class="li1">
<div class="de1"><span class="co1"># threading test</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Alex Boschmans</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># www.boschmans.net</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># January 2010</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># IMPORT SECTION</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">import</span> <span class="kw3">threading</span>, <span class="kw3">Queue</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Variables setup</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1">THREAD_LIMIT = <span class="nu0">3</span>                <span class="co1"># This is how many threads we want</span></div>
</li>
<li class="li1">
<div class="de1">jobs = <span class="kw3">Queue</span>.<span class="kw3">Queue</span><span class="br0">&#40;</span><span class="nu0">5</span><span class="br0">&#41;</span>           <span class="co1"># This sets up the queue object to use 5 slots</span></div>
</li>
<li class="li1">
<div class="de1">singlelock = <span class="kw3">threading</span>.<span class="me1">Lock</span><span class="br0">&#40;</span><span class="br0">&#41;</span>   <span class="co1"># This is a lock so threads don&#8217;t print trough each other (and other reasons)</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Our list of work todo</span></div>
</li>
<li class="li1">
<div class="de1">inputlist_ori = <span class="br0">&#91;</span> <span class="br0">&#40;</span><span class="nu0">5</span>,<span class="nu0">5</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">10</span>,<span class="nu0">4</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">78</span>,<span class="nu0">5</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">87</span>,<span class="nu0">2</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">65</span>,<span class="nu0">4</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">10</span>,<span class="nu0">10</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">65</span>,<span class="nu0">2</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">88</span>,<span class="nu0">95</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">44</span>,<span class="nu0">55</span><span class="br0">&#41;</span>,<span class="br0">&#40;</span><span class="nu0">33</span>,<span class="nu0">3</span><span class="br0">&#41;</span> <span class="br0">&#93;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># This is called from the main function</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># It spawns the threads, fills up the queue with work items that the threads will use</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># And then waits for the threads to finish</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># This could use some more try:except code&#8230;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">def</span> draadje<span class="br0">&#40;</span>inputlist<span class="br0">&#41;</span>:</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> <span class="st0">&quot;Inputlist received&#8230;&quot;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> inputlist</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Spawn the threads</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> <span class="st0">&quot;Spawning the {0} threads.&quot;</span>.<span class="me1">format</span><span class="br0">&#40;</span>THREAD_LIMIT<span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">for</span> x <span class="kw1">in</span> <span class="kw2">xrange</span><span class="br0">&#40;</span>THREAD_LIMIT<span class="br0">&#41;</span>:</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> <span class="st0">&quot;Thread {0} started.&quot;</span>.<span class="me1">format</span><span class="br0">&#40;</span>x<span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># This is the thread class that we instantiate.</span></div>
</li>
<li class="li1">
<div class="de1">workerbee<span class="br0">&#40;</span><span class="br0">&#41;</span>.<span class="me1">start</span><span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Put stuff in queue</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> <span class="st0">&quot;Putting stuff in queue&quot;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">for</span> i <span class="kw1">in</span> inputlist:</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Block if queue is full, and wait 5 seconds. After 5s raise Queue Full error.</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">try</span>:</div>
</li>
<li class="li1">
<div class="de1">jobs.<span class="me1">put</span><span class="br0">&#40;</span>i, block=<span class="kw2">True</span>, timeout=5<span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">except</span>:</div>
</li>
<li class="li1">
<div class="de1">singlelock.<span class="me1">acquire</span><span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> <span class="st0">&quot;The queue is full !&quot;</span></div>
</li>
<li class="li1">
<div class="de1">singlelock.<span class="me1">release</span><span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Wait for the threads to finish</span></div>
</li>
<li class="li1">
<div class="de1">singlelock.<span class="me1">acquire</span><span class="br0">&#40;</span><span class="br0">&#41;</span>        <span class="co1"># Acquire the lock so we can print</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> <span class="st0">&quot;Waiting for threads to finish.&quot;</span></div>
</li>
<li class="li1">
<div class="de1">singlelock.<span class="me1">release</span><span class="br0">&#40;</span><span class="br0">&#41;</span>        <span class="co1"># Release the lock</span></div>
</li>
<li class="li1">
<div class="de1">jobs.<span class="me1">join</span><span class="br0">&#40;</span><span class="br0">&#41;</span>                 <span class="co1"># This command waits for all threads to finish.</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Main thread class &#8211; based on threading.Thread</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># This class is cloned/used as a thread template to spawn those threads.</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># The class has a run function that gets a job out of the jobs queue</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># And lets the queue object know when it has finished.</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">class</span> workerbee<span class="br0">&#40;</span><span class="kw3">threading</span>.<span class="me1">Thread</span><span class="br0">&#41;</span>:</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">def</span> run<span class="br0">&#40;</span><span class="kw2">self</span><span class="br0">&#41;</span>:</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># run forever</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">while</span> <span class="nu0">1</span>:</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Try and get a job out of the queue</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">try</span>:</div>
</li>
<li class="li1">
<div class="de1">job = jobs.<span class="me1">get</span><span class="br0">&#40;</span><span class="kw2">True</span>,<span class="nu0">1</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">singlelock.<span class="me1">acquire</span><span class="br0">&#40;</span><span class="br0">&#41;</span>        <span class="co1"># Acquire the lock</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">print</span> <span class="st0">&quot;Multiplication of {0} with {1} gives {2}&quot;</span>.<span class="me1">format</span><span class="br0">&#40;</span>job<span class="br0">&#91;</span><span class="nu0">0</span><span class="br0">&#93;</span>,job<span class="br0">&#91;</span><span class="nu0">1</span><span class="br0">&#93;</span>,<span class="br0">&#40;</span>job<span class="br0">&#91;</span><span class="nu0">0</span><span class="br0">&#93;</span><span class="sy0">*</span>job<span class="br0">&#91;</span><span class="nu0">1</span><span class="br0">&#93;</span><span class="br0">&#41;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">singlelock.<span class="me1">release</span><span class="br0">&#40;</span><span class="br0">&#41;</span>        <span class="co1"># Release the lock</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Let the queue know the job is finished.</span></div>
</li>
<li class="li1">
<div class="de1">jobs.<span class="me1">task_done</span><span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">except</span>:</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">break</span>           <span class="co1"># No more jobs in the queue</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Executes if the program is started normally, not if imported</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">if</span> __name__ == <span class="st0">&#8216;__main__&#8217;</span>:</div>
</li>
<li class="li1">
<div class="de1"><span class="co1"># Call the mainfunction that sets up threading.</span></div>
</li>
<li class="li1">
<div class="de1">draadje<span class="br0">&#40;</span>inputlist_ori<span class="br0">&#41;</span></div>
</li>
</ol>
</div>
</div>
<p>Sigh. I just finished adding spaces to show where a def ends, and the damn code highlighter removed it again. Grrrrrr. If you want a copy of the code, let me know and I&#8217;ll update this post with a zipped copy of it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/02/03/simple-python-threading-thread-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Not using regular expressions (re or regex) to find a #hashtag (python).</title>
		<link>http://www.boschmans.net/2010/01/27/not-using-regular-expressions-re-or-regex-to-find-a-hashtag-python/</link>
		<comments>http://www.boschmans.net/2010/01/27/not-using-regular-expressions-re-or-regex-to-find-a-hashtag-python/#comments</comments>
		<pubDate>Wed, 27 Jan 2010 22:01:08 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[python]]></category>
		<category><![CDATA[regex]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=924</guid>
		<description><![CDATA[First, a quick reminder for myself: there&#8217;s an extremely good guide to regex on Andrew M. Kuchling&#8217;s pages.
Secondly, you don&#8217;t really *need* regex to parse for hashtags in a tweet &#8211; it&#8217;s a bit of overkill. The following code will do as well, and was written in 1 minute after searching 15 minutes in regex [...]]]></description>
			<content:encoded><![CDATA[<p>First, a quick reminder for myself: there&#8217;s an extremely good guide to regex on Andrew M. Kuchling&#8217;s <a title="Regex for python explanation" href="http://www.amk.ca/python/howto/regex/" target="_blank">pages</a>.</p>
<p>Secondly, you don&#8217;t really *need* regex to parse for hashtags in a tweet &#8211; it&#8217;s a bit of overkill. The following code will do as well, and was written in 1 minute after searching 15 minutes in regex how to make certain to include hyphens ( &#8211; ) and other non-characters if they are put into the hashtag.</p>
<p>The regular expression that I find works quite well for all hashtags that don&#8217;t have a hyphen in it:</p>
<div class="codesnip-container" >
<div class="python codesnip" style="font-family:monospace;">
<ol>
<li class="li1">
<div class="de1"><span class="sy0">&gt;&gt;&gt;</span> hashtag = <span class="st0">&quot;This is a #hashtag #test-link #a should#not#work&quot;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="sy0">&gt;&gt;&gt;</span> x = <span class="kw3">re</span>.<span class="kw2">compile</span><span class="br0">&#40;</span>r<span class="st0">&#8216;<span class="es0">\B</span>#<span class="es0">\w</span>+&#8217;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="sy0">&gt;&gt;&gt;</span> x.<span class="me1">findall</span><span class="br0">&#40;</span>hashtag<span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="br0">&#91;</span><span class="st0">&#8216;#hashtag&#8217;</span>, <span class="st0">&#8216;#test&#8217;</span>, <span class="st0">&#8216;#a&#8217;</span><span class="br0">&#93;</span></div>
</li>
</ol>
</div>
</div>
<p>So the above code correctly finds all words beginning with a hashtage, and not the ones that contain a hashtag inside the word. Note that the hyphen and the word after it is not included. </p>
<p>This is the short code I wrote that does all I want:</p>
<div class="codesnip-container" >
<div class="python codesnip" style="font-family:monospace;">
<ol>
<li class="li1">
<div class="de1"><span class="sy0">&gt;&gt;&gt;</span> hashtag = <span class="st0">&quot;This is a #hashtag #test-link #a should#not#work&quot;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="sy0">&gt;&gt;&gt;</span> <span class="kw1">for</span> word <span class="kw1">in</span> hashtag.<span class="me1">split</span><span class="br0">&#40;</span><span class="br0">&#41;</span>:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> word<span class="br0">&#91;</span><span class="nu0">0</span><span class="br0">&#93;</span> == <span class="st0">&quot;#&quot;</span>:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">print</span> word&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#hashtag</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#test-link</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">#a</span></div>
</li>
</ol>
</div>
</div>
<p>In section 6 of the above-mentioned guide, Andrew states that in some cases string methods (like split) are faster than using regex. For simplicity, I&#8217;m going to use the latter code.</p>
<p>Update: Grrr &#8211; discovered that the tweets I am processing are in html so have href tags around them &#8211; which means ofcourse that there are no blanks for me to split words in. After another unsuccessful session with regex and just to continue I&#8217;ve used the <a href="http://www.crummy.com/software/BeautifulSoup/">BeautifulSoup html parsing library</a> to get around that by stripping out all tags and then splitting the sentence up again. Probably not as efficient as immediately using regex, I&#8217;ll have to revisit this in the future.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/01/27/not-using-regular-expressions-re-or-regex-to-find-a-hashtag-python/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using threads in Python</title>
		<link>http://www.boschmans.net/2010/01/26/using-threads-in-python/</link>
		<comments>http://www.boschmans.net/2010/01/26/using-threads-in-python/#comments</comments>
		<pubDate>Tue, 26 Jan 2010 22:18:10 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=918</guid>
		<description><![CDATA[I&#8217;ve been trying to setup threading in Python, so that in the back-end of my service system that I&#8217;m developing I can query more than one source at the same time. So instead of querying one server and waiting for feedback, I can launch 10 threads and thus query 10 servers and process each server&#8217;s [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been trying to setup<a title="Threading in Python scripting language" href="http://docs.python.org/library/threading.html?highlight=thread#module-threading" target="_blank"> threading</a> in Python, so that in the back-end of my service system that I&#8217;m developing I can query more than one source at the same time. So instead of querying one server and waiting for feedback, I can launch 10 threads and thus query 10 servers and process each server&#8217;s feedback via it&#8217;s own thread.</p>
<p>So a very vague, generalising definition of a thread is an independent &#8216;process&#8217; that performs a job that you give it. You can control how many threads that you launch. Each thread is a copy of the original thread that you describe (in essence a python def function that has been wrapped in a thread class).</p>
<p>Right now, my understanding of threads is a bit confused. So far it seems that threading has several different manners of implementing them:</p>
<ul>
<li>using a number of threads that you launch, use, and forget about them (they go away)</li>
<li>improving on that by putting those threads in a thread pool, and when a thread finishes, re-using it for the next job (so you have  5 threads but 10 jobs to do, those five threads take five jobs, and the first thread that finishes takes on the sixth job, the second thread to finish the seventh job, and so on)</li>
<li>the final step seems to be (I haven&#8217;t got that far in my implementation) to set up worker bees that are managed by one thread (a better description is promised, as soon as I have understood it!)</li>
</ul>
<p>Since I&#8217;ve been scouring the net for information over threads, here is a list of resources that discuss, give examples, and explain threads &#8211; it&#8217;s useful for me to refer to, it might be useful for you as well :</p>
<ul>
<li>DaveN has <a title="DaveN, Search Engine Optimization" href="http://www.davidnaylor.co.uk/threaded-data-collection-with-python-including-examples.html" target="_blank">an extensive post</a>, with examples, building up gradually. It&#8217;s only at the end that you read that the code shown has never been run, which is a bit of a letdown. Still worth a good read though !!</li>
<li>A very thorough 25-page pdf documents that starts from the beginning is <a title="UC Davis explaining threading in Python" href="http://heather.cs.ucdavis.edu/~matloff/Python/PyThreads.pdf" target="_blank">available on the site of UC Davis</a>, University of California. It goes into all the nitty gritty details.</li>
<li>An example that uses workers in threads is found on <a title="Python threading using workers" href="http://www.taher-zadeh.com/blog/threading-in-python-tutorial" target="_blank">the blog of Danial Taherzadeh</a>.</li>
<li>Another one that discusses using multiple queues chained together can be <a title="IBM Developerworks - practical threaded programming in pytho" href="http://www.ibm.com/developerworks/aix/library/au-threadingpython/" target="_blank">found</a> on IBM&#8217;s developerworks site.</li>
<li>And the <a title="Halotis getting feeds into a db using python" href="http://www.halotis.com/2009/07/07/how-to-get-rss-content-into-an-sqlite-database-with-python-fast/" target="_blank">blog post from Halotis</a> that started my looking into threads&#8230;</li>
</ul>
<p>Right now I&#8217;m using threads in a thread pool, but I&#8217;m not doing something right &#8211; I noticed that while I have 10 jobs to do, only the first five get done, and the others &#8216;disappear&#8217;.</p>
<p>I guess the only way to get it working is to continue reading the information above <em>until it makes sense</em>. Sometimes I wonder if I&#8217;m not slightly masochistic, looking for challenges like that&#8230; ai me poor pounding head ! <img src='http://www.boschmans.net/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/01/26/using-threads-in-python/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Parrot AR.Drone &#8211; instant lust.</title>
		<link>http://www.boschmans.net/2010/01/13/parrot-ar-drone-instant-lust/</link>
		<comments>http://www.boschmans.net/2010/01/13/parrot-ar-drone-instant-lust/#comments</comments>
		<pubDate>Wed, 13 Jan 2010 17:50:04 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Blog News]]></category>
		<category><![CDATA[iphone]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=910</guid>
		<description><![CDATA[Wow. I just saw the advert for a new type of remote controlled helicopter called the Parrot AR.Drone, and I experienced instant want-it syndrome. It&#8217;s controlled via your iPhone, it&#8217;s not out yet, somewhere in 2010 but from what you see in the demo it is amazing !

It is helicopter on steriods, typically geek stuff, [...]]]></description>
			<content:encoded><![CDATA[<p>Wow. I just saw the advert for a new type of remote controlled helicopter called the <a title="Parrot.com AR Drone Quadricopter" href="http://ardrone2.parrot.com/parrot-ar-drone/en/" target="_blank">Parrot AR.Drone</a>, and I experienced instant want-it syndrome. It&#8217;s controlled via your iPhone, it&#8217;s not out yet, somewhere in 2010 but from what you see in the demo it is amazing !</p>
<p><object width="425" height="349"><param name="movie" value="http://www.youtube.com/v/V3KrFV0-WFw&#038;border=1&#038;color1=0xb1b1b1&#038;color2=0xcfcfcf&#038;hl=en_US&#038;feature=player_embedded&#038;fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowScriptAccess" value="always"></param><embed src="http://www.youtube.com/v/V3KrFV0-WFw&#038;border=1&#038;color1=0xb1b1b1&#038;color2=0xcfcfcf&#038;hl=en_US&#038;feature=player_embedded&#038;fs=1" type="application/x-shockwave-flash" allowfullscreen="true" allowScriptAccess="always" width="425" height="349"></embed></object></p>
<p>It is helicopter on steriods, typically geek stuff, and it looks damn cool.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/01/13/parrot-ar-drone-instant-lust/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Excel 2008 for Mac insists on using mm/dd/yyyy instead of dd/mm/yyyy !</title>
		<link>http://www.boschmans.net/2010/01/01/excel-2008-for-mac-insists-on-using-mmddyyyy-instead-of-ddmmyyyy/</link>
		<comments>http://www.boschmans.net/2010/01/01/excel-2008-for-mac-insists-on-using-mmddyyyy-instead-of-ddmmyyyy/#comments</comments>
		<pubDate>Fri, 01 Jan 2010 22:41:57 +0000</pubDate>
		<dc:creator>alex</dc:creator>
				<category><![CDATA[Blog News]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[excel]]></category>
		<category><![CDATA[microsoft]]></category>

		<guid isPermaLink="false">http://www.boschmans.net/?p=902</guid>
		<description><![CDATA[I&#8217;ve just discovered a really bothersome bug using Excel 2008 for Mac (I&#8217;m using the current latest version 12.2.3 of Excel 2008 for Mac). My date columns keep on insisting on using the US format of month-days-year, even when the mac time setting is set to Brussels, Belgium. There does not seem to be a [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve just discovered a really bothersome bug using Excel 2008 for Mac (I&#8217;m using the current latest version 12.2.3 of Excel 2008 for Mac). My date columns keep on insisting on <a title="MAC 2008 Date format" href="http://forum.soft32.com/mac/International-Date-Formats-Excel-ftopict109018.html" target="_blank">using the US format of month-days-year</a>, even when the mac time setting is set to Brussels, Belgium. There does not seem to be a way to fix the setting in Excel, and similar date format problems appear on forums already <a title="Excel 2004 Date format" href="http://forum.soft32.com/mac/reverts-date-format-ftopict84384.html" target="_blank">since Excel 2004</a>.</p>
<p>The workaround I found was to select the date format 01-Mar-2009, in other words show the month as a word instead of as a number. This way I&#8217;m sure that the date I&#8217;m typing in is correct. But really this is annoying me immensely.</p>
<p>Another workaround (haven&#8217;t tried it yet) so that Excel uses the underlying Mac date format is to NOT preselect CELLs and format them as DATES &#8211; just type the date in a normal cell using slashes and Excel will then convert the values to the correct international date as set by the mac&#8230; I&#8217;ll try that next time.</p>
<p>WHY hasn&#8217;t this been resolved yet !? What&#8217;s so hard about doing this the right way ? I know the answer ofcourse &#8211; it&#8217;s a big company and everyone there has to jump through 15 hoops simultaneously while hopping on one leg and signing delivery forms with a pen that only works 1 in 3 times <img src='http://www.boschmans.net/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.boschmans.net/2010/01/01/excel-2008-for-mac-insists-on-using-mmddyyyy-instead-of-ddmmyyyy/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
