<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8266865608792123597</id><updated>2012-02-16T10:56:09.012-08:00</updated><category term='mobile'/><category term='matlab'/><category term='linux'/><category term='scripting'/><category term='awk'/><category term='math'/><category term='web-server'/><category term='tools'/><category term='sysadmin'/><category term='java'/><category term='shell'/><category term='unix'/><category term='programming'/><category term='mac'/><category term='design'/><category term='windows'/><category term='.net'/><category term='vbscript'/><category term='cmd'/><category term='sed'/><category term='database'/><title type='text'>James'  blog</title><subtitle type='html'>Programming and System Administration</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>93</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6444975789196565285</id><published>2011-11-15T10:00:00.000-08:00</published><updated>2011-11-15T10:10:28.646-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='awk'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='web-server'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Script to convert IIRF rules to IIS Rewrite</title><content type='html'>Use this script in Linux or Cygwin&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Example conversion:&lt;br /&gt;&lt;br /&gt;#individual page redirects&lt;br /&gt;RedirectRule ^/default.php http://example.com [R=301]&lt;br /&gt;&lt;br /&gt;Converts to:&lt;br /&gt;&lt;br /&gt;&amp;lt;rule name="RULE_no1"&gt;&amp;lt;match url="^/default.php" /&gt;&amp;lt;action type="Redirect" redirectType="Permanent" url="http://example.com" /&gt; &amp;lt;/rule&gt; &lt;br /&gt;&lt;br /&gt;Script:&lt;br /&gt;&lt;br /&gt;&lt;pre style="overflow : auto"&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;&lt;br /&gt;awk 'BEGIN{OFS=""}/RedirectRule/{ print "&amp;lt;rule name=\"RULE_no",NR,"\"&gt;&amp;lt;match url=\"",$2,"\" /&gt;&amp;lt;action type=\"Redirect\" redirectType=\"Permanent\" url=\"",$3,"\" /&gt; &amp;lt;/rule&gt; " }' $1&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6444975789196565285?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6444975789196565285/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6444975789196565285' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6444975789196565285'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6444975789196565285'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2011/11/script-to-convert-iirf-rules-to-iis.html' title='Script to convert IIRF rules to IIS Rewrite'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3674033463692160470</id><published>2011-09-13T19:57:00.000-07:00</published><updated>2011-09-15T18:36:26.554-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>CMD exercise : filtering for files that don't have a keyword</title><content type='html'>Problem:&lt;br /&gt;&lt;br /&gt;Need to find the keyword "ORDER, " in a large folder of txt files.  Need to move all files that don't have this keyword to another folder.&lt;br /&gt;&lt;br /&gt;How do I count the number string instances for all files in a directory?&lt;br /&gt;&lt;br /&gt;Here is an example of looking for the string "ORDER, " in all txt files.&lt;br /&gt;&lt;br /&gt;find /C  "ORDER, " *.txt&lt;br /&gt;&lt;br /&gt;How do I filter for items with a count of zero?&lt;br /&gt;&lt;br /&gt;find /C  "ORDER, " *.txt | findstr /c:": 0"&lt;br /&gt;&lt;br /&gt;This is because each line in the output of find comes up:&lt;br /&gt;&lt;br /&gt;---------- stats-2011-09-13.TXT: 0&lt;br /&gt;---------- stats-2011-09-12.TXT: 12&lt;br /&gt;&lt;br /&gt;What if I want to move all files from a list to some folder?&lt;br /&gt;&lt;br /&gt;First output your results by doing redirection.&lt;br /&gt;&lt;br /&gt;find /C  "ORDER, " *.txt | findstr /c:": 0" &gt; list.txt&lt;br /&gt;&lt;br /&gt;You can open the file and strip out everything except the filename and extension. Once that's done, just use a for loop to move everything in list.txt.&lt;br /&gt;&lt;br /&gt;for /f %a in ('type list.txt') do move %a no_orders&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3674033463692160470?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3674033463692160470/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3674033463692160470' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3674033463692160470'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3674033463692160470'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2011/09/how-to-check-what-files-dont-have.html' title='CMD exercise : filtering for files that don&apos;t have a keyword'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8044363954576305209</id><published>2011-06-25T10:18:00.000-07:00</published><updated>2011-06-25T10:28:05.740-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='.net'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Old School VS .net 2005 MFC Threading and Timers</title><content type='html'>I come from a background of multithreading with Java. I also did some threading with pthreads.&lt;br /&gt;&lt;br /&gt;CWinThreads don't seem to have the same level of control that java has. &lt;br /&gt;&lt;br /&gt;To create a CWinThread, use this :&lt;br /&gt;&lt;br /&gt;AfxBeginThread(ProcName, NULL, THREAD_PRIORITY_NORMAL, 0, 0, NULL);&lt;br /&gt;&lt;br /&gt;Using AfxBeginThread allows you to access MFC objects.&lt;br /&gt;&lt;br /&gt;Make sure you create global function:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;UINT ProcName(LPVOID param)&lt;br /&gt;&lt;br /&gt;{&lt;br /&gt;&lt;br /&gt; for(int i=0; i&lt;100000000; i++)&lt;br /&gt;&lt;br /&gt; {&lt;br /&gt;  if (i % 10000000 == 0){&lt;br /&gt;&lt;br /&gt;   TRACE("thread 2 id = %d, %d \n",AfxGetThread()-&gt;m_nThreadID,i);&lt;br /&gt;  }&lt;br /&gt;  &lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; return 0;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;You probably noticed the AfxGetThread() function which gives you access to the current thread. Very helpful function.&lt;br /&gt;&lt;br /&gt;It looks like CWinThread uses preemptive multitasking but it's kind of slow, doing like context switches every second or so.&lt;br /&gt;&lt;br /&gt;I also played with the MFC timer. This doesn't create a new thread whenever the timer function executes. It uses the same thread as is used in the GUI (I was using a dialog project). This is also much too slow. You can set the timer to every millisec. Would be nice to have it down to microsec.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8044363954576305209?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8044363954576305209/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8044363954576305209' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8044363954576305209'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8044363954576305209'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2011/06/old-school-vs-net-2005-mfc-threading.html' title='Old School VS .net 2005 MFC Threading and Timers'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7962948231699776415</id><published>2011-06-24T13:20:00.001-07:00</published><updated>2011-06-25T07:58:31.022-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Convert text to html codes</title><content type='html'>I was surprised there was no simple script out here to do this conversion. I took the an table of html ascii and wrote this bash script.&lt;br /&gt;&lt;br /&gt;I know there are functions to convert text to ascii. I didn't want to go through the hassle of formatting it for HTML. &lt;br /&gt;&lt;br /&gt;This script accepts as input the text you want to convert and also a html formatted table of ascii codes.&lt;br /&gt;&lt;br /&gt;&lt;div style="overflow : auto"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;# $1 input text&lt;br /&gt;# $2 ascii table&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;to_process=$1&lt;br /&gt;res=""&lt;br /&gt;for ((i=0;i&lt;${#to_process};i++))&lt;br /&gt;{&lt;br /&gt; letter=${to_process:i:1}&lt;br /&gt;&lt;br /&gt; if [[ $letter == "." ]]&lt;br /&gt; then&lt;br /&gt;  res="${res} &amp;amp;#46;"&lt;br /&gt; else&lt;br /&gt;  line_no=`grep -n "&amp;#60;td&gt;$letter&amp;#60;/td&gt;" $2 | cut -f 1 -d ':'`&lt;br /&gt;  ((line_no++))&lt;br /&gt;&lt;br /&gt;  if [[ ${#line_no} -gt 0 ]]&lt;br /&gt;  then&lt;br /&gt;&lt;br /&gt;   part=`sed -n "${line_no}p" $2 | sed -e 's/&amp;#60;td&gt;//' -e  's/&lt;\/td&gt;//'`&lt;br /&gt;   res=${res}${part}&lt;br /&gt;&lt;br /&gt;  fi&lt;br /&gt;&lt;br /&gt; fi&lt;br /&gt;}&lt;br /&gt;echo $res | sed -e 's/amp\;//g' -e 's/ //g' &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;Here is the table I used:&lt;br /&gt;&lt;div style="overflow : auto"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&amp;#60;table cellspacing="0" border="1" width="100%" class="reference"&gt;&lt;br /&gt;    &amp;#60;tbody&gt;&amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;th align="left"&gt;ASCII Character&amp;#60;/th&gt;&lt;br /&gt;      &amp;#60;th align="left"&gt;HTML Entity Code&amp;#60;/th&gt;&lt;br /&gt;      &amp;#60;th align="left"&gt;Description&amp;#60;/th&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;nbsp;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#32;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;space&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;!&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#33;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;exclamation mark&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;"&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#34;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;quotation mark&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;#&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#35;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;number sign&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;$&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#36;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;dollar sign&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;%&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#37;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;percent sign&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#38;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;ampersand&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;'&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#39;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;apostrophe&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;(&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#40;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;left parenthesis&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;)&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#41;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;right parenthesis&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;*&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#42;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;asterisk&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;+&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#43;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;plus sign&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;,&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#44;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;comma&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;-&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#45;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;hyphen&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;.&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#46;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;period&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;/&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#47;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;slash&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;0&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#48;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 0&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;1&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#49;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 1&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;2&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#50;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 2&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;3&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#51;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 3&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;4&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#52;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 4&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;5&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#53;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 5&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;6&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#54;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 6&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;7&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#55;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 7&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;8&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#56;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 8&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;9&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#57;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;digit 9&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;:&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#58;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;colon&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#59;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;semicolon&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;lt;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#60;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;less-than&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;=&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#61;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;equals-to&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;gt;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#62;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;greater-than&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;?&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#63;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;question mark&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;@&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#64;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;at sign&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;A&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#65;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase A&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;B&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#66;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase B&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;C&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#67;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase C&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;D&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#68;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase D&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;E&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#69;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase E&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;F&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#70;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase F&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;G&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#71;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase G&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;H&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#72;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase H&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;I&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#73;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase I&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;J&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#74;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase J&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;K&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#75;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase K&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;L&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#76;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase L&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;M&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#77;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase M&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;N&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#78;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase N&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;O&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#79;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase O&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;P&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#80;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase P&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;Q&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#81;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase Q&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;R&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#82;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase R&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;S&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#83;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase S&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;T&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#84;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase T&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;U&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#85;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase U&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;V&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#86;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase V&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;W&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#87;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase W&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;X&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#88;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase X&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;Y&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#89;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase Y&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;Z&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#90;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;uppercase Z&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;[&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#91;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;left square bracket&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;\&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#92;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;backslash&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;]&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#93;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;right square bracket&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;^&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#94;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;caret&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;_&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#95;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;underscore&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;`&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#96;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;grave accent&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;a&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#97;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase a&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;b&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#98;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase b&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;c&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#99;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase c&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;d&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#100;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase d&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;e&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#101;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase e&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;f&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#102;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase f&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;g&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#103;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase g&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;h&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#104;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase h&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;i&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#105;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase i&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;j&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#106;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase j&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;k&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#107;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase k&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;l&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#108;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase l&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;m&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#109;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase m&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;n&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#110;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase n&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;o&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#111;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase o&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;p&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#112;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase p&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;q&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#113;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase q&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;r&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#114;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase r&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;s&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#115;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase s&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;t&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#116;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase t&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;u&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#117;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase u&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;v&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#118;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase v&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;w&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#119;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase w&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;x&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#120;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase x&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;y&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#121;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase y&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;z&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#122;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;lowercase z&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;{&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#123;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;left curly brace&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;|&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#124;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;vertical bar&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;}&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#125;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;right curly brace&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;    &amp;#60;tr&gt;&lt;br /&gt;      &amp;#60;td&gt;~&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;&amp;amp;#126;&amp;#60;/td&gt;&lt;br /&gt;      &amp;#60;td&gt;tilde&amp;#60;/td&gt;&lt;br /&gt;    &amp;#60;/tr&gt;&lt;br /&gt;&amp;#60;/tbody&gt;&amp;#60;/table&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7962948231699776415?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7962948231699776415/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7962948231699776415' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7962948231699776415'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7962948231699776415'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2011/06/convert-text-to-html-codes.html' title='Convert text to html codes'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7432311465345057037</id><published>2010-05-14T18:39:00.000-07:00</published><updated>2010-05-14T18:41:12.998-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Tool to manage power for ppc Linux</title><content type='html'>ACPI is n/a for ppc. Same for apm. Those don't work with the ppc hardware. Pbbuttonsd controls sleep and hibernate. And for PPC Linux, you must have an ATI graphics card for sleep to work. Nvidia and anything else will not work.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;$ sudo pbbcmd hibernate&lt;br /&gt;&lt;br /&gt;or &lt;br /&gt;&lt;br /&gt;$ sudo pbbcmd sleep&lt;br /&gt;&lt;br /&gt;or&lt;br /&gt;&lt;br /&gt;$ sudo pbbuttonsd sleep&lt;br /&gt;&lt;br /&gt;or&lt;br /&gt;&lt;br /&gt;$ sudo pbbuttonsd hibernate&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7432311465345057037?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7432311465345057037/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7432311465345057037' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7432311465345057037'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7432311465345057037'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/05/tool-to-manage-power-for-ppc-linux.html' title='Tool to manage power for ppc Linux'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4876843943369997805</id><published>2010-04-18T11:04:00.000-07:00</published><updated>2011-06-25T10:39:19.491-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Python - test urlopen function</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;import urllib&lt;br /&gt;f = urllib.urlopen("http://www.google.com")&lt;br /&gt;print f.read()&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4876843943369997805?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4876843943369997805/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4876843943369997805' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4876843943369997805'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4876843943369997805'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/04/python-test-urlopen-function.html' title='Python - test urlopen function'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7025565991198974782</id><published>2010-04-05T19:55:00.000-07:00</published><updated>2010-04-05T20:15:13.208-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Flash Card to Moodle xml</title><content type='html'>#example flashcard questions:&lt;br /&gt;Which switch would you use with the echo command to enable the "backslash" options? ------ -e&lt;br /&gt;Which switch would you use with the find utility to cause another command to run without prompting you? ------ -exec&lt;br /&gt;&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;#shell script&lt;br /&gt;#!/bin/sh&lt;br /&gt;converted="converted.xml"&lt;br /&gt;sep="------"&lt;br /&gt;&lt;br /&gt;if [[ $# -ne 1 ]]&lt;br /&gt;then&lt;br /&gt;        echo "$0 file_to_convert"&lt;br /&gt;        exit 1&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;echo "starting conversion to moodle xml"&lt;br /&gt;&lt;br /&gt;if [[ -f $converted ]]&lt;br /&gt;then&lt;br /&gt;        echo "$converted already exists"&lt;br /&gt;        rm $converted&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;echo '&amp;lt;?xml version="1.0" ?&amp;gt;' &amp;gt; $converted&lt;br /&gt;echo "&amp;lt;quiz&amp;gt;" &amp;gt;&amp;gt; $converted&lt;br /&gt;&lt;br /&gt;i=1&lt;br /&gt;&lt;br /&gt;cat $1 | while read line&lt;br /&gt;do&lt;br /&gt;&lt;br /&gt;        q=`echo $line  | awk -F"$sep" '{  print $1 }'`&lt;br /&gt;        a=`echo $line | awk -F"$sep" '{  print $2 }'`&lt;br /&gt;        echo '&amp;lt;question type="shortanswer"&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo '&amp;lt;name&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo "&amp;lt;text&amp;gt;Question $i&amp;lt;/text&amp;gt;" &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo '&amp;lt;/name&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo '&amp;lt;questiontext format="html"&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo "&amp;lt;text&amp;gt;$q&amp;lt;/text&amp;gt;" &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo '&amp;lt;/questiontext&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo '&amp;lt;answer fraction = "100"&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo "&amp;lt;text&amp;gt;$a&amp;lt;/text&amp;gt;" &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo '&amp;lt;feedback&amp;gt;&amp;lt;text&amp;gt;Correct!&amp;lt;/text&amp;gt;&amp;lt;/feedback&amp;gt;' &amp;gt;&amp;gt;$converted&lt;br /&gt;        echo '&amp;lt;/answer&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;        echo '&amp;lt;/question&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;&lt;br /&gt;        ((i=i+1))&lt;br /&gt;&lt;br /&gt;done&lt;br /&gt;echo '&amp;lt;/quiz&amp;gt;' &amp;gt;&amp;gt; $converted&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7025565991198974782?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7025565991198974782/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7025565991198974782' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7025565991198974782'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7025565991198974782'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/04/flash-card-to-moodle-xml.html' title='Flash Card to Moodle xml'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2360370732767297934</id><published>2010-03-30T12:22:00.000-07:00</published><updated>2010-03-30T12:23:41.048-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Linux - wireless commands</title><content type='html'>wireless commands&lt;br /&gt;&lt;br /&gt;iwlist wlan0 scan&lt;br /&gt;wevent &amp;amp;&lt;br /&gt;iwconfig wlan0 key open xxxxx&lt;br /&gt;iwconfig wlan0 essid xxxx&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2360370732767297934?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2360370732767297934/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2360370732767297934' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2360370732767297934'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2360370732767297934'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/03/linux-wireless-commands.html' title='Linux - wireless commands'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1416968069696973552</id><published>2010-03-17T08:00:00.001-07:00</published><updated>2010-03-17T08:00:43.131-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Set program output to environment variable in batch file</title><content type='html'>&lt;h3&gt; &lt;/h3&gt;  &lt;div&gt;FOR /F "tokens=*" %A IN ('prog.exe') DO SET ENVVAR=%A &lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1416968069696973552?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1416968069696973552/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1416968069696973552' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1416968069696973552'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1416968069696973552'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/03/set-program-output-to-environment.html' title='Set program output to environment variable in batch file'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-452584393726021656</id><published>2010-03-17T07:50:00.000-07:00</published><updated>2010-03-17T07:53:57.420-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>gcc, gdb and make commands</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Macro definition&lt;/span&gt;&lt;br /&gt;gcc -D DUMMY_DEF -c test_str.c&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Makefile arguments&lt;/span&gt;&lt;br /&gt;test:&lt;br /&gt;       ./program $(PROG_ARGS)&lt;br /&gt;&lt;br /&gt;make test PROG_ARGS='testfile1.txt'&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;gdb commands&lt;/span&gt;&lt;br /&gt;run args - runs program&lt;br /&gt;frame - examines current frame&lt;br /&gt;up - examines previous frame&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-452584393726021656?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/452584393726021656/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=452584393726021656' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/452584393726021656'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/452584393726021656'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/03/gcc-gdb-and-make-commands.html' title='gcc, gdb and make commands'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7212822989642077676</id><published>2010-02-24T12:56:00.000-08:00</published><updated>2010-02-24T12:57:10.270-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Mount smb from command line</title><content type='html'>mount -t smbfs //username@ip/share mountpt&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7212822989642077676?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7212822989642077676/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7212822989642077676' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7212822989642077676'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7212822989642077676'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/02/mount-smb-from-command-line.html' title='Mount smb from command line'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8732102029907293695</id><published>2010-01-24T15:31:00.000-08:00</published><updated>2011-06-25T08:33:32.814-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Mortgage calculator - bash script</title><content type='html'>This simply outputs the monthly mortgage payment.&lt;br /&gt;&lt;br /&gt;Takes five arguments : principle years interest points fees&lt;br /&gt;&lt;br /&gt;For instance, &lt;br /&gt;&lt;br /&gt;bash mortgage.sh 100000 5 .075 0 0&lt;br /&gt;&lt;br /&gt;Outputs&lt;br /&gt;&lt;br /&gt;Principle + fees = 100000 , Years = 5 , Months = 60 , interest .006250000000&lt;br /&gt;Points = 0 , 0&lt;br /&gt;2003.794859563881&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style = "overflow : auto"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;&lt;br /&gt;if [[ $# -ne 5 ]]&lt;br /&gt;then&lt;br /&gt; echo "enter 5 args : principle years interest points fees"&lt;br /&gt;  exit&lt;br /&gt;  fi&lt;br /&gt;&lt;br /&gt;  prin=$1&lt;br /&gt;  ((mon=$2 * 12 ))&lt;br /&gt;  inter=`echo "scale=12;$3/12" | bc`&lt;br /&gt;  pts=`echo "scale=12; $prin * $4" | bc`&lt;br /&gt;  fee=$5&lt;br /&gt;  prin=`echo "scale=12;$prin + $fee" | bc`&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  echo "Principle + fees = $prin , Years = $2 , Months = $mon , interest $inter"&lt;br /&gt;  echo "Points = $4 , $pts"&lt;br /&gt;&lt;br /&gt;  prin=`echo "scale=12; $prin - $pts" | bc`&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  echo `echo "scale=12;($prin*$inter)*((1+$inter)^$mon)/(((1+$inter)^$mon)-1)"|bc`&lt;br /&gt;  echo "the monthly payment : $new_prin"&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8732102029907293695?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8732102029907293695/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8732102029907293695' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8732102029907293695'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8732102029907293695'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/01/mortgage-calculator-bash-script.html' title='Mortgage calculator - bash script'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6446825733708830679</id><published>2010-01-17T19:19:00.001-08:00</published><updated>2011-06-25T10:37:38.736-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>start menu pin list location</title><content type='html'>&lt;div style="OVERFLOW: auto"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&gt; If I pin a shortcut to the startmenu, where does XP store this&lt;br /&gt;&gt; information?&lt;br /&gt;&lt;br /&gt;With a shortcut in this folder...&lt;br /&gt;C:\Documents and Settings\All Users\Start Menu&lt;br /&gt;&lt;br /&gt;The above folder would be the easiest.&lt;br /&gt;&lt;br /&gt;Also here...&lt;br /&gt;HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\&lt;br /&gt;Explorer\MenuOrder\Start Menu2\Programs&lt;br /&gt;Value Name: Order&lt;br /&gt;&lt;br /&gt;HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\&lt;br /&gt;Explorer\StartPage&lt;br /&gt;Value Name: Favorites&lt;br /&gt;Value Name: FavoritesResolve&lt;br /&gt;&lt;br /&gt;All of those are REG_BINARY values and hard to read them.&lt;br /&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6446825733708830679?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6446825733708830679/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6446825733708830679' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6446825733708830679'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6446825733708830679'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/01/start-menu-pin-list-location.html' title='start menu pin list location'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7459380415280636419</id><published>2010-01-11T12:54:00.000-08:00</published><updated>2010-01-11T13:02:23.158-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Bash - Gaussian Elimination Op count example</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;&lt;br /&gt;if [[ $# -ne 2 ]]&lt;br /&gt;then&lt;br /&gt; exit&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;echo " m $1 by n $2 matrix"&lt;br /&gt;&lt;br /&gt;n=$2&lt;br /&gt;m=$1&lt;br /&gt;mult=0&lt;br /&gt;add=0&lt;br /&gt;c=0&lt;br /&gt;&lt;br /&gt;for ((i=1;i &amp;#60; m;i++))&lt;br /&gt;do&lt;br /&gt; echo "row = i = $i"&lt;br /&gt; for ((j=i;j &amp;#60; m;j++))&lt;br /&gt; do&lt;br /&gt;  ((mult=mult + (n-i+1)))&lt;br /&gt;  ((add=add + (n-i+1)))&lt;br /&gt; done&lt;br /&gt; ((c=c+(m-i)*(n-i+1)))&lt;br /&gt;done&lt;br /&gt;echo "additions = $add"&lt;br /&gt;echo "mults = $mult"&lt;br /&gt;echo "summation = $c"&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7459380415280636419?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7459380415280636419/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7459380415280636419' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7459380415280636419'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7459380415280636419'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/01/bash-gaussian-elimination-op-count.html' title='Bash - Gaussian Elimination Op count example'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3382179216542280944</id><published>2010-01-11T12:52:00.000-08:00</published><updated>2010-01-11T12:53:10.411-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>Matlab - simple newton's method ex</title><content type='html'>&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;function r = doNewton(f,x0,x,err)&lt;br /&gt; &lt;br /&gt; while abs(x0 - x) &gt; err&lt;br /&gt;  &lt;br /&gt;  x0, (x0 - x)&lt;br /&gt;&lt;br /&gt;  x0 = x0 - (polyval(f,x0))/polyval(polyder(f),x0);&lt;br /&gt;&lt;br /&gt;  &lt;br /&gt; end&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;&lt;br /&gt; r = x0;&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3382179216542280944?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3382179216542280944/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3382179216542280944' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3382179216542280944'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3382179216542280944'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2010/01/matlab-simple-newtons-method-ex.html' title='Matlab - simple newton&apos;s method ex'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1516844209074077503</id><published>2009-11-07T11:17:00.000-08:00</published><updated>2011-06-25T07:56:18.510-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>Jacobi Method example</title><content type='html'>I wrote this code a while back. Apparently, this post is getting a few hits. I refined it a bit. Also wanted to make sure it was looked right.&lt;br /&gt;&lt;br /&gt;What is the Jacobi method? It's an iterative way of solving a system of equations. Ax = b. This is learned in Numerical Analysis classes.&lt;br /&gt;&lt;br /&gt;Generally, you decompose a matrix into its diagonal and lower and upper triangles. Such that, &lt;br /&gt;&lt;br /&gt;A = D + L + U&lt;br /&gt;&lt;br /&gt;x0 is the initial guess.&lt;br /&gt;&lt;br /&gt;Now you want to solve for x. x_approx = inverse of D * (b - (L+U)x0)&lt;br /&gt;&lt;br /&gt;Get x_approx from this formula, then plug it into x0 and do it all over again until you reach the desired error.&lt;br /&gt;&lt;br /&gt;&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;% Code is for matlab / octave&lt;br /&gt;format long e;&lt;br /&gt;A = [ 2 -1; -1 2];&lt;br /&gt;b = [ 2; 1];&lt;br /&gt;k = 20;&lt;br /&gt;xi = [0;0]; % initial guess&lt;br /&gt;&lt;br /&gt;%we want&lt;br /&gt;%x' = Dinv(b - (L+U)x)&lt;br /&gt;&lt;br /&gt;% just take the diagonal of A&lt;br /&gt;D=[A(1,1) 0;0 A(2,2)]; &lt;br /&gt;&lt;br /&gt;Di=inv(D);&lt;br /&gt;&lt;br /&gt;%lower and upper triangles of A&lt;br /&gt;L=[0 0; -A(2,1) 0];&lt;br /&gt;U=[0 -A(1, 2); 0 0];&lt;br /&gt;&lt;br /&gt;% this part doesn't change, so calc now&lt;br /&gt;C=Di*b;&lt;br /&gt;% this is the main term of the algo&lt;br /&gt;M=Di*(L+U);&lt;br /&gt;&lt;br /&gt;x = [5/3; 4/3]; % solution&lt;br /&gt;&lt;br /&gt;abs_err = [ 100 ; 100];&lt;br /&gt;abs_err = abs_err - x;&lt;br /&gt;i=0;&lt;br /&gt;&lt;br /&gt;%stop until error is &lt;= 1e-6&lt;br /&gt;while abs_err(1) &gt;= 1e-6 &amp;&amp; abs_err(2) &gt;= 1e-6&lt;br /&gt; xi=M*xi+C&lt;br /&gt; abs_err = abs(xi - x);&lt;br /&gt; fprintf('i = %f abs-err = %f %f \n',i,abs_err(1),abs_err(2));&lt;br /&gt; i=i+1;&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1516844209074077503?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1516844209074077503/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1516844209074077503' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1516844209074077503'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1516844209074077503'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/11/jacobi-method-example.html' title='Jacobi Method example'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6274959123369097273</id><published>2009-11-06T16:00:00.000-08:00</published><updated>2009-11-06T16:05:37.132-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab : polynomial fitting</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;octave-3.2.3:4&gt; for i = 1 : 51&lt;br /&gt;&gt; x(i) = .2*(i - 1);&lt;br /&gt;&gt; end&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;octave-3.2.3:6&gt; for i = 1: 51&lt;br /&gt;&gt; y(i) = 1 - x(i);&lt;br /&gt;&gt; end&lt;br /&gt;&lt;br /&gt;octave-3.2.3:8&gt; polyfit(x,y,4)&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;   1.1249e-17  -2.3654e-16   1.7285e-15  -1.0000e+00   1.0000e+00&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6274959123369097273?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6274959123369097273/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6274959123369097273' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6274959123369097273'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6274959123369097273'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/11/matlab-polynomial-fitting.html' title='matlab : polynomial fitting'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5816951901521960248</id><published>2009-11-04T06:00:00.001-08:00</published><updated>2009-11-05T16:39:16.905-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Java : sample applet</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt; &lt;br /&gt; import java.applet.*;&lt;br /&gt; import java.awt.*;&lt;br /&gt; &lt;br /&gt; public class A extends Applet&lt;br /&gt; {&lt;br /&gt;        private int w, h;&lt;br /&gt;        public void init( )&lt;br /&gt;        {&lt;br /&gt;         w = 45;&lt;br /&gt;         h = 50;&lt;br /&gt;        }&lt;br /&gt;    &lt;br /&gt;        public void paint(Graphics g)&lt;br /&gt;        {&lt;br /&gt;         g.drawRect(w, h, 20, 80);&lt;br /&gt;        }&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5816951901521960248?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5816951901521960248/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5816951901521960248' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5816951901521960248'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5816951901521960248'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/11/java-sample-applet.html' title='Java : sample applet'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-155227523540076419</id><published>2009-11-04T05:57:00.000-08:00</published><updated>2009-11-04T05:59:06.086-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='mobile'/><title type='text'>Sample J2Me Midlet for sound recording</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;import java.io.*;&lt;br /&gt;import javax.microedition.midlet.*;&lt;br /&gt;import javax.microedition.lcdui.*;&lt;br /&gt;import javax.microedition.media.*;&lt;br /&gt;import javax.microedition.media.control.*;&lt;br /&gt;&lt;br /&gt;public class VoiceRecordMidlet extends MIDlet {&lt;br /&gt;      private Display display;&lt;br /&gt;&lt;br /&gt;      public void startApp() {&lt;br /&gt;            display = Display.getDisplay(this);&lt;br /&gt;            display.setCurrent(new VoiceRecordForm());&lt;br /&gt;      }&lt;br /&gt;&lt;br /&gt;      public void pauseApp() {&lt;br /&gt;      }&lt;br /&gt;&lt;br /&gt;      public void destroyApp(boolean unconditional) {&lt;br /&gt;            notifyDestroyed();&lt;br /&gt;      }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;class VoiceRecordForm extends Form implements CommandListener {&lt;br /&gt;      private StringItem message;&lt;br /&gt;      private StringItem errormessage;&lt;br /&gt;      private final Command record, play;&lt;br /&gt;      private Player player;&lt;br /&gt;      private byte[] recordedAudioArray = null;&lt;br /&gt;      public VoiceRecordForm() {&lt;br /&gt;            super("Recording Audio");&lt;br /&gt;            message = new StringItem("", "Select Record to start recording.");&lt;br /&gt;            this.append(message);&lt;br /&gt;            errormessage = new StringItem("", "");&lt;br /&gt;            this.append(errormessage);&lt;br /&gt;            record = new Command("Record", Command.OK, 0);&lt;br /&gt;            this.addCommand(record);&lt;br /&gt;            play = new Command("Play", Command.BACK, 0);&lt;br /&gt;            this.addCommand(play);&lt;br /&gt;            this.setCommandListener(this);&lt;br /&gt;      }&lt;br /&gt;      public void commandAction(Command comm, Displayable disp) {&lt;br /&gt;            if (comm == record) {&lt;br /&gt;                  Thread t = new Thread() {&lt;br /&gt;                        public void run() {&lt;br /&gt;                              try {&lt;br /&gt;                                    player = Manager.createPlayer("capture://audio?encoding=pcm");&lt;br /&gt;                                    player.realize();&lt;br /&gt;                                    RecordControl rc = (RecordControl) player.getControl("RecordControl");&lt;br /&gt;                                    ByteArrayOutputStream output = new ByteArrayOutputStream();&lt;br /&gt;                                    rc.setRecordStream(output);&lt;br /&gt;                                    rc.startRecord();&lt;br /&gt;                                    player.start();&lt;br /&gt;                                    message.setText("Recording...");&lt;br /&gt;                                    Thread.sleep(5000);&lt;br /&gt;                                    message.setText("Recording Done!");&lt;br /&gt;                                    rc.commit();&lt;br /&gt;                                    recordedAudioArray = output.toByteArray();&lt;br /&gt;                                    player.close();&lt;br /&gt;                              } catch (Exception e) {&lt;br /&gt;                                    errormessage.setLabel("Error");&lt;br /&gt;                                    errormessage.setText(e.toString());&lt;br /&gt;                              }&lt;br /&gt;                        }&lt;br /&gt;                  };&lt;br /&gt;                  t.start();&lt;br /&gt;&lt;br /&gt;            }&lt;br /&gt;            else if (comm == play) {&lt;br /&gt;                  try {&lt;br /&gt;                        ByteArrayInputStream recordedInputStream = new ByteArrayInputStream(recordedAudioArray);&lt;br /&gt;                        Player p2 = Manager.createPlayer(recordedInputStream, "audio/basic");&lt;br /&gt;                        p2.prefetch();&lt;br /&gt;                        p2.start();&lt;br /&gt;                  } catch (Exception e) {&lt;br /&gt;                        errormessage.setLabel("Error");&lt;br /&gt;                        errormessage.setText(e.toString());&lt;br /&gt;                  }&lt;br /&gt;            }&lt;br /&gt;      }&lt;br /&gt;} &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-155227523540076419?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/155227523540076419/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=155227523540076419' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/155227523540076419'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/155227523540076419'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/11/sample-j2me-midlet-for-sound-recording.html' title='Sample J2Me Midlet for sound recording'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8666950753846731272</id><published>2009-10-30T20:18:00.000-07:00</published><updated>2009-10-30T20:20:31.230-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>Matlab polynomial basics: roots, derivative of polynomial, evaluate polynomial</title><content type='html'>&lt;div style="overflow:auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;%Get roots of function&lt;br /&gt;&lt;br /&gt;octave-3.2.3:13&gt; A = [1 -3 3 -1]&lt;br /&gt;A =&lt;br /&gt;&lt;br /&gt;   1  -3   3  -1&lt;br /&gt;&lt;br /&gt;octave-3.2.3:14&gt; roots(A)&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;   1.00001 + 0.00000i&lt;br /&gt;   1.00000 + 0.00001i&lt;br /&gt;   1.00000 - 0.00001i&lt;br /&gt;&lt;br /&gt;%get derivative of polynomial&lt;br /&gt;&lt;br /&gt;octave-3.2.3:18&gt; A&lt;br /&gt;A =&lt;br /&gt;&lt;br /&gt;   1  -2   1&lt;br /&gt;&lt;br /&gt;octave-3.2.3:19&gt; polyder(A)&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;   2  -2&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;%evaluate polynomial using matrix notation&lt;br /&gt;&lt;br /&gt; polyval(A,1)&lt;br /&gt;ans = 0&lt;br /&gt;octave-3.2.3:21&gt; polyval(A,2)&lt;br /&gt;ans =  1&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8666950753846731272?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8666950753846731272/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8666950753846731272' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8666950753846731272'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8666950753846731272'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-polynomial-basics-roots.html' title='Matlab polynomial basics: roots, derivative of polynomial, evaluate polynomial'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8132363038453056249</id><published>2009-10-11T21:53:00.000-07:00</published><updated>2011-06-25T10:28:59.077-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab : example program to find extreme points of lp problem</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;format compact;&lt;br /&gt;A=[2 1 1 1 0 0; 1 -2 1  0 1 0; 1 1 0 0 0 1];&lt;br /&gt;&lt;br /&gt;b = [ 10; 8; 3];&lt;br /&gt;c= [-1 1 1 0 0 0];&lt;br /&gt;&lt;br /&gt;n = 3;&lt;br /&gt;m = 3;&lt;br /&gt;&lt;br /&gt;i = 1;&lt;br /&gt;while i &lt;= n+1&lt;br /&gt;        j = i+1;&lt;br /&gt;        while j &lt; n+m&lt;br /&gt;                k=j+1;&lt;br /&gt;                while k &lt;=n+m&lt;br /&gt;                        B=[A(:,[i j k]) b];&lt;br /&gt;                        B=rref(B);&lt;br /&gt;                        temp = [ 0 ; 0 ; 0; 0; 0; 0];&lt;br /&gt;                        x = B(:,[n+1]);&lt;br /&gt;                        fprintf(1,'***Is feasible __ ***');&lt;br /&gt;                        fprintf(1,'i=%d,j=%d,k=%d \n',i,j,k);&lt;br /&gt;                        temp(i) = x(1);&lt;br /&gt;                        temp(j) = x(2);&lt;br /&gt;                        temp(k) = x(3);&lt;br /&gt;                        temp&lt;br /&gt;                        c*temp&lt;br /&gt;                        B=0;&lt;br /&gt;                        x=0;&lt;br /&gt;                        k=k+1;&lt;br /&gt;&lt;br /&gt;                end&lt;br /&gt;                j=j+1;&lt;br /&gt;        end&lt;br /&gt;        i=i+1;&lt;br /&gt;end&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8132363038453056249?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8132363038453056249/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8132363038453056249' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8132363038453056249'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8132363038453056249'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-example-program-to-find-extreme.html' title='matlab : example program to find extreme points of lp problem'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6124616868641618482</id><published>2009-10-11T12:02:00.000-07:00</published><updated>2009-10-11T12:03:02.134-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab basics : matrix norms, condition number</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;A =&lt;br /&gt;&lt;br /&gt;     1     0    -2&lt;br /&gt;     2     2     2&lt;br /&gt;     2     2     4&lt;br /&gt;&lt;br /&gt;&gt;&gt; norm(A)&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;    6.0225&lt;br /&gt;&lt;br /&gt;%infinity norm&lt;br /&gt;&lt;br /&gt;&gt;&gt; norm(A,'inf')&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;     8&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;%condition numbers&lt;br /&gt;&gt;&gt; cond(A)  &lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;   19.5212&lt;br /&gt;&lt;br /&gt;&gt;&gt; cond(A,'inf')&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;    36&lt;br /&gt;&lt;br /&gt;&gt;&gt; norm(A)*norm(inv(A))&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;   19.5212&lt;br /&gt;&lt;br /&gt;&gt;&gt; norm(A,'inf')*norm(inv(A),'inf')&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;    36&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6124616868641618482?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6124616868641618482/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6124616868641618482' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6124616868641618482'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6124616868641618482'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-basics-matrix-norms-condition.html' title='matlab basics : matrix norms, condition number'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-939149255610415201</id><published>2009-10-11T09:11:00.000-07:00</published><updated>2009-10-11T09:13:47.895-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab basics : matrix num elements, row/column operations, lu decomposition</title><content type='html'>&lt;div style="overflow : auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;%num of matrix elements&lt;br /&gt;numel(A)&lt;br /&gt;&lt;br /&gt;%example of row/col operations for complete pivoting&lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     1     0    -2     1&lt;br /&gt;     2     2     2     0&lt;br /&gt;     2     2     4     0&lt;br /&gt;&lt;br /&gt;%swop rows 1 and 3&lt;br /&gt;&gt;&gt; B([1 3],:) = B([3 1],:)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     2     2     4     0&lt;br /&gt;     2     2     2     0&lt;br /&gt;     1     0    -2     1&lt;br /&gt;&lt;br /&gt;%swop columns 1 and 3&lt;br /&gt;&gt;&gt; B( :,[1 3]) = B(:,[3 1])&lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     4     2     2     0&lt;br /&gt;     2     2     2     0&lt;br /&gt;    -2     0     1     1&lt;br /&gt;&lt;br /&gt;% it is now z y x &lt;br /&gt;&lt;br /&gt;&gt;&gt; B(2,:) = (-1/2)*B(1,:) + B(2,:)&lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     4     2     2     0&lt;br /&gt;     0     1     1     0&lt;br /&gt;    -2     0     1     1&lt;br /&gt;&lt;br /&gt;&gt;&gt; B(3,:) = (1/2)*B(1,:) + B(3,:) &lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     4     2     2     0&lt;br /&gt;     0     1     1     0&lt;br /&gt;     0     1     2     1&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&gt;&gt; B([2 3],:) = B([3 2],:)        &lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     4     2     2     0&lt;br /&gt;     0     1     2     1&lt;br /&gt;     0     1     1     0&lt;br /&gt;&lt;br /&gt;&gt;&gt; B( :,[2 3]) = B(:,[3 2])       &lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     4     2     2     0&lt;br /&gt;     0     2     1     1&lt;br /&gt;     0     1     1     0&lt;br /&gt;&lt;br /&gt;%it is now z x y&lt;br /&gt;&lt;br /&gt;&gt;&gt; B(3,:) = (-1/2) * B(2,:) + B(3,:)&lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;    4.0000    2.0000    2.0000         0&lt;br /&gt;         0    2.0000    1.0000    1.0000&lt;br /&gt;         0         0    0.5000   -0.5000&lt;br /&gt;&lt;br /&gt;&gt;&gt; rref(B)&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;     1     0     0     0&lt;br /&gt;     0     1     0     1&lt;br /&gt;     0     0     1    -1&lt;br /&gt;&lt;br /&gt;%x = 1&lt;br /&gt;%y = -1&lt;br /&gt;%z = 0&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;%lu decomposition&lt;br /&gt;&lt;br /&gt;[L,U]=lu(some_matrix)&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-939149255610415201?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/939149255610415201/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=939149255610415201' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/939149255610415201'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/939149255610415201'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-basics-matrix-num-elements.html' title='matlab basics : matrix num elements, row/column operations, lu decomposition'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3277031381559553584</id><published>2009-10-10T17:07:00.000-07:00</published><updated>2009-10-10T17:08:46.145-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab : sample Gauss Elimination</title><content type='html'>&lt;pre&gt;&lt;br /&gt;A = [ 2 1 -1 8; -3 -1 2 -11; -2 1 2 -3]&lt;br /&gt;&lt;br /&gt;m = 3&lt;br /&gt;n = 4&lt;br /&gt;&lt;br /&gt;i = 1&lt;br /&gt;&lt;br /&gt;adds=0 %just counting the additions&lt;br /&gt;mults=0 % just counting the multiplications&lt;br /&gt;&lt;br /&gt;while i &lt; m&lt;br /&gt;        j = i+1&lt;br /&gt;        while j &lt;= m&lt;br /&gt;                temp = -(A(j,i)/A(i,i))&lt;br /&gt;                k = i&lt;br /&gt;                while k &lt;= n&lt;br /&gt;                        A(j,k) = A(j,k) + A(i,k)*temp&lt;br /&gt;                        adds=adds+1&lt;br /&gt;                        mults=mults+1&lt;br /&gt;                        k=k+1&lt;br /&gt;                end&lt;br /&gt;                j=j+1&lt;br /&gt;        end&lt;br /&gt;        i=i+1&lt;br /&gt;end&lt;br /&gt;A&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3277031381559553584?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3277031381559553584/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3277031381559553584' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3277031381559553584'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3277031381559553584'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-sample-gauss-elimination.html' title='matlab : sample Gauss Elimination'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-9038030007402322641</id><published>2009-10-10T17:05:00.000-07:00</published><updated>2009-10-10T17:07:14.067-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab : sample cholesky program</title><content type='html'>&lt;pre&gt;&lt;br /&gt;A = [2 4 2; 4 11 4; 2 4 6]&lt;br /&gt;&lt;br /&gt;j = 1&lt;br /&gt;n = 3&lt;br /&gt;&lt;br /&gt;while j &lt;= n&lt;br /&gt;        k = 1&lt;br /&gt;        while k &lt; j&lt;br /&gt;                i = j&lt;br /&gt;                while i &lt;= n&lt;br /&gt;                        A(i,j) = A(i,j) - A(i,k)*A(j,k)&lt;br /&gt;                        i=i+1&lt;br /&gt;                end&lt;br /&gt;                k = k+1&lt;br /&gt;        end&lt;br /&gt;        A(j,j) = (A(j,j)).^(1/2)&lt;br /&gt;        k = j+1&lt;br /&gt;        while k &lt;= n&lt;br /&gt;                A(k,j) = (A(k,j))/(A(j,j))&lt;br /&gt;                k = k+1&lt;br /&gt;        end&lt;br /&gt;        j = j+1&lt;br /&gt;end&lt;br /&gt;A&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-9038030007402322641?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/9038030007402322641/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=9038030007402322641' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/9038030007402322641'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/9038030007402322641'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-sample-cholesky-program.html' title='matlab : sample cholesky program'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3641529427585196310</id><published>2009-10-10T14:13:00.000-07:00</published><updated>2009-10-10T14:14:14.143-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab basics : inverse matrices, transpose</title><content type='html'>matlab basics : inverse matrices, transpose&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&gt;&gt; B = [ 2 0 ; 3 1]&lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     2     0&lt;br /&gt;     3     1&lt;br /&gt;&lt;br /&gt;&gt;&gt; inv(B)&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;    0.5000         0&lt;br /&gt;   -1.5000    1.0000&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;transpose&lt;br /&gt;&lt;br /&gt;&gt;&gt; B = [2 0; 3 1]&lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     2     0&lt;br /&gt;     3     1&lt;br /&gt;&lt;br /&gt;&gt;&gt; B'&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;     2     3&lt;br /&gt;     0     1&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3641529427585196310?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3641529427585196310/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3641529427585196310' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3641529427585196310'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3641529427585196310'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-basics-inverse-matrices.html' title='matlab basics : inverse matrices, transpose'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5765428161234831443</id><published>2009-10-06T20:30:00.000-07:00</published><updated>2009-10-06T20:41:56.144-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab basics : matrices</title><content type='html'>% 3 by 3 matrix&lt;br /&gt;&lt;br /&gt;A = [ 2 1 1&lt;br /&gt;1 -2 1&lt;br /&gt;1 1 0]&lt;br /&gt;&lt;br /&gt;A =&lt;br /&gt;&lt;br /&gt;     2     1     1&lt;br /&gt;     1    -2     1&lt;br /&gt;     1     1     0&lt;br /&gt;&lt;br /&gt;% column vector&lt;br /&gt;&lt;br /&gt;b = [10; 8; 3]&lt;br /&gt;&lt;br /&gt;b =&lt;br /&gt;&lt;br /&gt;    10&lt;br /&gt;     8&lt;br /&gt;     3&lt;br /&gt;&lt;br /&gt;% matrix multiplication&lt;br /&gt;&lt;br /&gt;A * [1; 0; 0]&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;     2&lt;br /&gt;     1&lt;br /&gt;     1&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;% index operations&lt;br /&gt;&lt;br /&gt;A(1:3)&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;     2     1     1&lt;br /&gt;&lt;br /&gt;&gt;&gt; A(1:4)&lt;br /&gt;&lt;br /&gt;ans =&lt;br /&gt;&lt;br /&gt;     2     1     1     1&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;% adding 3 columns to the A matrix and assigning result to B&lt;br /&gt;B = [A(1:3) 1 0 0; A(4:6) 0 1 0; A(7:9) 0 0 1] &lt;br /&gt;&lt;br /&gt;B =&lt;br /&gt;&lt;br /&gt;     2     1     1     1     0     0&lt;br /&gt;     1    -2     1     0     1     0&lt;br /&gt;     1     1     0     0     0     1&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;% the rref function for solving a linear system&lt;br /&gt;&lt;br /&gt;rref(A)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5765428161234831443?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5765428161234831443/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5765428161234831443' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5765428161234831443'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5765428161234831443'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-basics-matrices.html' title='matlab basics : matrices'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6261156011572306745</id><published>2009-10-03T16:26:00.001-07:00</published><updated>2009-10-03T16:26:53.683-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='matlab'/><category scheme='http://www.blogger.com/atom/ns#' term='math'/><title type='text'>matlab basics :  scripts, functions, precision</title><content type='html'>running scripts&lt;br /&gt;===============&lt;br /&gt;&lt;br /&gt;matlab -r myscript&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;creating and using a function&lt;br /&gt;=============================&lt;br /&gt;&lt;br /&gt;g = inline('9*(s.^6) + 6*(s.^5) - 11*(s.^4) - 4*(s.^3) - 5*(s.^2) + 12*s - 4')&lt;br /&gt;&lt;br /&gt;g(1)&lt;br /&gt;&lt;br /&gt;precision display&lt;br /&gt;=================&lt;br /&gt;&lt;br /&gt;format long e %15 digits with exponent&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6261156011572306745?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6261156011572306745/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6261156011572306745' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6261156011572306745'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6261156011572306745'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/10/matlab-basics-scripts-functions.html' title='matlab basics :  scripts, functions, precision'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6877147794751263834</id><published>2009-09-05T19:34:00.000-07:00</published><updated>2011-06-25T10:31:41.392-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Removing unwanted characters from a text file with grep</title><content type='html'># This worked pretty good when I was getting strange characters from uploading a google text file to my linux box&lt;br /&gt;#I couldn't import into mysql&lt;br /&gt;#So I did this:&lt;br /&gt;&lt;br /&gt;cat $1 | grep -o "[a-zA-Z,;()0-9_ ][a-zA-Z,;()0-9_ *@'.]*" &gt; output.sql&lt;br /&gt;&lt;br /&gt;#this command greps for only letters,commas, numbers, underscores, parenthesis, semicolons, astericks, and at signs.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6877147794751263834?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6877147794751263834/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6877147794751263834' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6877147794751263834'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6877147794751263834'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/09/removing-unwanted-characters-from-text.html' title='Removing unwanted characters from a text file with grep'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1503278990332627501</id><published>2009-09-03T20:19:00.000-07:00</published><updated>2009-09-03T20:22:18.063-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='vbscript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Cut out unwanted pieces of a lastname with vbscript</title><content type='html'>&lt;div style='overflow : auto'&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;lastname = "DE' CA-R LO III"&lt;br /&gt;&lt;br /&gt;'separate lastname by spaces into an array&lt;br /&gt;a = split(lastname," ")&lt;br /&gt;new_lastname = a(0)&lt;br /&gt;&lt;br /&gt;for i = 0 to ubound(a) -1 ' add each chunk of the last name to the final string&lt;br /&gt;'the last piece of the last name is not added if it is less than 4 characters (such as III, II, I, etc)&lt;br /&gt;    if i + 1 = ubound(a) and len(a(i+1)) &gt; 3 then&lt;br /&gt;        new_lastname = new_lastname + a(i+1)&lt;br /&gt;    elseif i + 1&lt; ubound(a) then&lt;br /&gt;        new_lastname = new_lastname + a(i+1)&lt;br /&gt;    end if&lt;br /&gt;next&lt;br /&gt;&lt;br /&gt;new_lastname = Replace(new_lastname,"-","") 'take out hyphens&lt;br /&gt;new_lastname = Replace(new_lastname,"'","") 'take out punctuations&lt;br /&gt;&lt;br /&gt;wscript.echo new_lastname&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1503278990332627501?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1503278990332627501/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1503278990332627501' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1503278990332627501'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1503278990332627501'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/09/cut-out-unwanted-pieces-of-lastname.html' title='Cut out unwanted pieces of a lastname with vbscript'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2045090177480733168</id><published>2009-08-31T20:10:00.000-07:00</published><updated>2009-08-31T20:11:48.343-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Linux mail basics</title><content type='html'># Start interactive mail&lt;br /&gt;mail&lt;br /&gt;&lt;br /&gt;# Print current message&lt;br /&gt;p&lt;br /&gt;&lt;br /&gt;# Delete current message&lt;br /&gt;d&lt;br /&gt;&lt;br /&gt;#Exit mail program&lt;br /&gt;q&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2045090177480733168?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2045090177480733168/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2045090177480733168' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2045090177480733168'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2045090177480733168'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/08/linux-mail-basics.html' title='Linux mail basics'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8178063821920204932</id><published>2009-08-28T11:57:00.000-07:00</published><updated>2009-08-28T11:58:06.757-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Leopard user template</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 13px; "&gt;sudo mv /System/Library/User\ Template/English.lproj /System/Library/User\ Template/English.lproj.old&lt;br /&gt;&lt;br /&gt;This will give you copy of the original called "English.lproj.old" in the same folder. Then you may copy your new template file by executing:&lt;br /&gt;&lt;br /&gt;sudo cp -R /Users/new-user-short-name /System/Library/User\ Template/English.lproj&lt;br /&gt;&lt;br /&gt;If you prefer to remove (delete) the original try the command without the /* at the end: sudo rm -r /System/Library/User\ Template/English.lproj&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8178063821920204932?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8178063821920204932/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8178063821920204932' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8178063821920204932'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8178063821920204932'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/08/leopard-user-template.html' title='Leopard user template'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6991246132680826979</id><published>2009-08-28T11:51:00.000-07:00</published><updated>2011-06-29T21:06:39.218-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Get mac address from xml and generate computer names for each mac</title><content type='html'>Parsing xml is pretty easy using grep. The benefit of sed/grep is that they are right there -- if you have cygwin, Linux or Mac.&lt;br /&gt;&lt;br /&gt;Here is an example format:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;&amp;#60;macs&gt;&lt;br /&gt;&lt;br /&gt;&amp;#60;string&gt;00-00-00-00-00-01&amp;#60;/string&gt;&lt;br /&gt;&amp;#60;string&gt;00-00-00-00-00-02&amp;#60;/string&gt;&lt;br /&gt;&amp;#60;/macs&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;This will parse the xml file formatted like above and generate a computer name for each mac address. A good application of sed/grep/bash. If you are installing a lot of new computers and need to associate new names with mac addresses, this is a good start.&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;div style="overflow : auto"&gt;grep All\ Computers.plist | sed -e 's/&lt;\/*string&gt;//g' | while read line; do ((i++)); echo "pc-$i $line"; done &gt; macs.txt&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6991246132680826979?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6991246132680826979/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6991246132680826979' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6991246132680826979'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6991246132680826979'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/08/get-mac-address-from-xml-and-add.html' title='Get mac address from xml and generate computer names for each mac'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5517176998272089027</id><published>2009-08-21T10:58:00.000-07:00</published><updated>2009-08-21T11:01:47.210-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Set the default printer from the registry</title><content type='html'>rem Using reg.exe you can set the default printer&lt;br /&gt;&lt;br /&gt;@echo off&lt;br /&gt;&lt;br /&gt;rem Here we are doing a split of the hostname on the hypen, so room1-01, becomes room1&lt;br /&gt;&lt;br /&gt;for /F "tokens=1 delims=-" %%a in ('hostname') do set name=%%a&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;if %name% == room1 ( reg add "hkcu\software\microsoft\windows nt\currentversion\windows" /t REG_SZ /d "ROOM1PRINTER,winspool,NE04:" /v "Device" /f&lt;br /&gt;  )&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5517176998272089027?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5517176998272089027/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5517176998272089027' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5517176998272089027'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5517176998272089027'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/08/set-default-printer-from-registry.html' title='Set the default printer from the registry'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1964987302475971757</id><published>2009-08-20T13:27:00.000-07:00</published><updated>2009-09-10T07:27:52.391-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Installing a folder tree of fonts on XP</title><content type='html'>rem XP doesn't let you select a folder to install fonts from; it will not recurse to find fonts within a folder unless they are all under one folder&lt;br /&gt;&lt;br /&gt;rem This command will go through all folders in the current directory and copy the files to all_fonts&lt;br /&gt;&lt;br /&gt;rem The /y for copy will force an overwrite if a duplicate file shows up&lt;br /&gt;&lt;br /&gt;for /F "tokens=1 delims=," %a in ('dir /s /b') do copy /y "%a" all_fonts&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1964987302475971757?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1964987302475971757/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1964987302475971757' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1964987302475971757'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1964987302475971757'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/08/installing-folder-tree-of-fonts-on-xp.html' title='Installing a folder tree of fonts on XP'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4285546334957127401</id><published>2009-08-04T15:59:00.000-07:00</published><updated>2009-08-04T16:00:42.598-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>mysql -- attaching to a host</title><content type='html'>#This is a way checking your connection to a mysql db server&lt;br /&gt;&lt;br /&gt;mysql --user=username -h hostname -p&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4285546334957127401?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4285546334957127401/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4285546334957127401' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4285546334957127401'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4285546334957127401'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/08/mysql-attaching-to-host.html' title='mysql -- attaching to a host'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5759206958574976855</id><published>2009-07-09T18:54:00.000-07:00</published><updated>2009-07-09T20:07:55.388-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><title type='text'>GPG Error with APT</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Get a gpg error when apt-get update&lt;/span&gt;&lt;br /&gt;&lt;span&gt;&lt;span style="border-collapse: collapse; line-height: 18px;"&gt;&lt;br /&gt;The time is incorrect; do this:&lt;br /&gt;&lt;p&gt;apt-get install ntpdate&lt;br /&gt;ntpdate &lt;a href="http://pool.ntp.org/"&gt;pool.ntp.org&lt;/a&gt;&lt;/p&gt;&lt;p&gt;then again:-&lt;/p&gt;&lt;p&gt;apt-get update&lt;/p&gt;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5759206958574976855?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5759206958574976855/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5759206958574976855' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5759206958574976855'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5759206958574976855'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/07/gpg-error-with-apt.html' title='GPG Error with APT'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2417297232516423844</id><published>2009-06-24T05:42:00.000-07:00</published><updated>2009-06-24T05:58:43.254-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Replacing folders on a network with psexec and xcopy</title><content type='html'>rem We can run a process remotely with psexec&lt;br /&gt;rem&lt;br /&gt;rem cmd /C allows us to run a process in a cmd window and it automatically terminates&lt;br /&gt;&lt;br /&gt;for /l %a in (1,1,50) do &lt;a href="file://server/es122/graphics_labs/psexec"&gt;psexec&lt;/a&gt;  &lt;a href="file://station/"&gt;\\station&lt;/a&gt;-%a cmd /C  "move c:\path\to\folder c:\path\to\backup"&lt;br /&gt;&lt;br /&gt;rem Now lets replace that folder with a new one using xcopy&lt;br /&gt;rem&lt;br /&gt;rem We use our local copy of the folder c:\path\to\folder and copy it to each station&lt;br /&gt;rem&lt;br /&gt;rem /S /E /H /I switches for xcopy ensure that we get hidden files, sub directories, and empty directories. /I assumes that the destination is a folder.&lt;br /&gt;&lt;br /&gt;for /l %a in (1,1,50) do start cmd /k "xcopy /S /E /H /I c:\path\to\folder &lt;a href="file://station-%25a/c$/path/to/folder"&gt;\\station-%a\c$\path\to\folder&lt;/a&gt;"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2417297232516423844?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2417297232516423844/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2417297232516423844' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2417297232516423844'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2417297232516423844'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/replacing-folders-on-network-with.html' title='Replacing folders on a network with psexec and xcopy'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2512961199130564332</id><published>2009-06-17T05:41:00.001-07:00</published><updated>2009-06-17T05:41:37.275-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>Get mac serial no from terminal</title><content type='html'>system_profiler SPHardwareDataType | grep "Serial Number" | sed 's/Serial Number://'&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2512961199130564332?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2512961199130564332/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2512961199130564332' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2512961199130564332'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2512961199130564332'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/get-mac-serial-no-from-terminal.html' title='Get mac serial no from terminal'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3065379264374550150</id><published>2009-06-16T18:42:00.000-07:00</published><updated>2011-06-25T10:39:00.036-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Php basics :  error handling, tests, array functs, classes, and scope</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Checking if a file exists&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;if (file_exists($some_file)){&lt;br /&gt;...&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Basic Error Handling&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;function($var) or exit("some error");&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;br /&gt;Printing an array&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;print_r();&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Creating a class&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;class SomeClass{&lt;br /&gt;&lt;br /&gt;private some_var;&lt;br /&gt;&lt;br /&gt; public function SomeClass(){}&lt;br /&gt;&lt;br /&gt; public function new_fun($r){&lt;br /&gt;         print_r($r);&lt;br /&gt;echo $this-&gt;some_var;&lt;br /&gt;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Defining an array&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;$my_array = array('elem1','elem2');&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Adding an array element&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;array_push($array,$elem)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Checking if a key exists&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;array_key_exists("some_name",$r)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Using a global var  in a function&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;global $global_var;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3065379264374550150?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3065379264374550150/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3065379264374550150' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3065379264374550150'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3065379264374550150'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/php-basics-file-tests-array-functs.html' title='Php basics :  error handling, tests, array functs, classes, and scope'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3172603577797747931</id><published>2009-06-16T18:35:00.000-07:00</published><updated>2011-06-25T10:36:42.120-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='design'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>JQuery basics : working with divs and text boxes, and checking for null elements</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Adding text to a div's innerHTML&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;$("div#some_div").append(s);&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Getting text from a div&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;var text = $("div#some_div" ).html();&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Getting/Setting value from text box&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;var text = $("#some_textbox").val();&lt;br /&gt;$("#some_textbox").val("bla");&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Checking if document element is null&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;if (!$("#some_elem").length){&lt;br /&gt;...&lt;br /&gt;&lt;br /&gt;}&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3172603577797747931?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3172603577797747931/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3172603577797747931' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3172603577797747931'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3172603577797747931'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/jquery-basics-working-with-divs-and.html' title='JQuery basics : working with divs and text boxes, and checking for null elements'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5496047352045347408</id><published>2009-06-15T18:03:00.000-07:00</published><updated>2011-06-29T21:03:38.989-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Get the distance between two latitude/longitude points in km (example)</title><content type='html'>Here is a python script to convert lat/lng point to meters. It expects the points to be entered in as decimal degrees. It outputs the distance in km.&lt;br /&gt;&lt;br /&gt;For example:&lt;br /&gt;&lt;br /&gt;python distlatlng.py 36.12 -86.67 33.94 -118.40&lt;br /&gt;the distance in km is  2887.25995061&lt;br /&gt;&lt;br /&gt;&lt;div style="overflow: auto;"&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#uses the haversine formula&lt;br /&gt;# based on code from http://www.movable-type.co.uk/scripts/latlong.html&lt;br /&gt;import math, sys&lt;br /&gt;&lt;br /&gt;def main(*args):&lt;br /&gt; if len(args) &lt; 5:&lt;br /&gt;  print args[0]," lng1 lat1 lng2 lat2 (finds distance between two lat/lng pairs)"&lt;br /&gt;  return&lt;br /&gt; lat1 = float(args[1]) &lt;br /&gt; lng1 = float(args[2])&lt;br /&gt; lat2 = float(args[3])&lt;br /&gt; lng2 = float(args[4])&lt;br /&gt; radius = 6372.8 # earth's mean radium in km&lt;br /&gt; dlat = math.radians(lat2-lat1)&lt;br /&gt; dlng = math.radians(lng2-lng1)&lt;br /&gt; a = math.sin(dlat/2) * math.sin(dlat/2) + math.cos(math.radians(lat1)) * math.cos(math.radians(lat2)) * math.sin(dlng/2)*math.sin(dlng/2)&lt;br /&gt; c = 2*math.atan2(math.sqrt(a),math.sqrt(1-a))&lt;br /&gt; dist = radius*c &lt;br /&gt; print "the distance in km is " , dist&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;if __name__ == "__main__":&lt;br /&gt; main(*sys.argv)&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5496047352045347408?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5496047352045347408/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5496047352045347408' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5496047352045347408'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5496047352045347408'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/converting-latitudelongitude-points-to.html' title='Get the distance between two latitude/longitude points in km (example)'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6953081390641436649</id><published>2009-06-15T17:58:00.001-07:00</published><updated>2011-06-25T10:39:49.291-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Python basics : math functions, main funct</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Math functions&lt;/span&gt;&lt;br /&gt;#Unfortunately, you need to import math, but python has a nice library of math functions&lt;br /&gt;&lt;div style='overflow : auto'&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;import math&lt;br /&gt;math.pow(2,3)&lt;br /&gt;math.cos(math.pi/2)  #&lt;-- radians!&lt;br /&gt;math.pi&lt;br /&gt;math.sqrt(4)&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Main function&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;#Making a main function in Python is a little tricky. Here is an example:&lt;br /&gt;&lt;div style='overflow : auto'&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;br /&gt;def main(*args):&lt;br /&gt;        if len(args) &lt; 4:&lt;br /&gt;                return&lt;br /&gt;      &lt;br /&gt;        print "main : args[0] ", args[0], " args[1]", args[1]&lt;br /&gt;        print "(main) : args[1] ", args[2]&lt;br /&gt;        print "(main) : args[3] ", args[3]&lt;br /&gt;      &lt;br /&gt;if __name__ == "__main__":&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6953081390641436649?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6953081390641436649/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6953081390641436649' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6953081390641436649'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6953081390641436649'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/python-basics-math-functions-main-funct.html' title='Python basics : math functions, main funct'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8637898543528267339</id><published>2009-06-14T15:50:00.000-07:00</published><updated>2009-06-14T15:55:18.420-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Mysql --  get table engine type</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Get table engine type&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;You have to go to the mysql system database 1st&lt;br /&gt;&lt;br /&gt;This allows you to see which type of table engine you're using&lt;br /&gt;&lt;br /&gt;Common types:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;myisam&lt;/span&gt;: doesn't support the features listed below for innodb&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;innodb&lt;/span&gt; (default) : supports r-trees (good for spatial extensions), enforces foreign keys, and supports transactions&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;select table_name, engine from tables where table_schema = "vsn";&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8637898543528267339?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8637898543528267339/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8637898543528267339' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8637898543528267339'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8637898543528267339'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/mysql-get-table-engine-type.html' title='Mysql --  get table engine type'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3792014200240906815</id><published>2009-06-12T11:36:00.000-07:00</published><updated>2009-06-12T11:37:41.936-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Silent install of msp patch</title><content type='html'>msiexec /p mspfile.msp /qn&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3792014200240906815?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3792014200240906815/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3792014200240906815' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3792014200240906815'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3792014200240906815'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/silent-install-of-msp-patch.html' title='Silent install of msp patch'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2322671570042682291</id><published>2009-06-11T11:31:00.000-07:00</published><updated>2009-06-11T11:36:18.327-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Checking versions if Office 2004 is at 11.5.5 and Acrobat is at 9.1.2</title><content type='html'>This is a trick to check version of some software on a group of computers&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;span style="font-weight: bold;"&gt;&lt;span style="font-weight: bold;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;Here we're checking that Office 2004 11.5.5 update is installed&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;for ((i=1;i &lt; 21;i++)); do if [[ $i -lt 10 ]]; then echo "station $i" ; ssh station-0${i}.local " ls -l /Applications/Microsoft\ Office\ 2004/Updater\ Logs/11.5.5\ Update\ Log.txt "; else ssh station-${i}.local " ls -l /Applications/Microsoft\ Office\ 2004/Updater\ Logs/11.5.5\ Update\ Log.txt "; fi; done&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Here we're checking that Acrobat reader and acrobat are at 9.1.2&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;for ((i=1;i &lt; 21;i++)); do if [[ $i -lt 10 ]]; then echo "station $i" ; ssh station-0${i}.local "system_profiler SPSoftwareDataType  SPApplicationsDataType | grep '9.1.2'  "; else ssh station-${i}.local " system_profiler SPSoftwareDataType  SPApplicationsDataType | grep '9.1.2' "; fi; done&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2322671570042682291?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2322671570042682291/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2322671570042682291' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2322671570042682291'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2322671570042682291'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/checking-versions-if-office-2004-is-at.html' title='Checking versions if Office 2004 is at 11.5.5 and Acrobat is at 9.1.2'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3232445707467176123</id><published>2009-06-10T19:16:00.000-07:00</published><updated>2011-06-25T10:33:44.939-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>How to set up Jogre for the web</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Set up jdk, apache tomcat, and hsqldb&lt;/span&gt;&lt;br /&gt;==============================&lt;br /&gt;&lt;br /&gt;apt-get install sun-java6-jdk&lt;br /&gt;apt-get install tomcat5.5 tomcat5.5-wepapps tomcat5.5-admin&lt;br /&gt;apt-get install hsqldb-server&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Set up jogre&lt;/span&gt;&lt;br /&gt;=========&lt;br /&gt;&lt;br /&gt;wget http://voxel.dl.sourceforge.net/sourceforge/jogre/jogre_beta_0.3_bin.zip&lt;br /&gt;cd /opt&lt;br /&gt;unzip ~/jogre_beta_0.3.bin.zip&lt;br /&gt;adduser jogre&lt;br /&gt;chown -R jogre:jogre jogre&lt;br /&gt;su jogre&lt;br /&gt;cd&lt;br /&gt;echo "export CLASSPATH=$CLASSPATH:/usr/share/java/hsqldb.jar:." &gt;&gt; .profile&lt;br /&gt;source .profile&lt;br /&gt;java org.hsqldb.Server &amp;amp;&lt;br /&gt;cd /opt/jogre/server&lt;br /&gt;chmod a+x *.sh&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Configuration&lt;/span&gt;&lt;br /&gt;==========&lt;br /&gt;&lt;br /&gt;./server.sh &amp;amp;&lt;br /&gt;&lt;br /&gt;#I prefer the gui; it's easier to just change the db settings with this tool&lt;br /&gt;./administrator.sh &amp;amp;&lt;br /&gt;#Login with admin, admin&lt;br /&gt;#Change the database from xml to hsqldb&lt;br /&gt;#The path to the db is jdbc:hsqldb:hsql://localhost/jogre_hsqldb&lt;br /&gt;&lt;br /&gt;#restart the jogre server&lt;br /&gt;killall server.sh&lt;br /&gt;./server.sh &amp;amp;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#With apache tomcat admin (http://localhost:8180/admin), add jogreweb.war&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3232445707467176123?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3232445707467176123/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3232445707467176123' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3232445707467176123'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3232445707467176123'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/how-to-set-up-jogre-for-web.html' title='How to set up Jogre for the web'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5471108497035079506</id><published>2009-06-09T20:24:00.001-07:00</published><updated>2009-06-10T19:21:57.674-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>How to start another X session</title><content type='html'>You already have X running and want to run another one.&lt;br /&gt;&lt;br /&gt;1. Login into another virtual console&lt;br /&gt;2. Open the terminal&lt;br /&gt;3. startx -- :1&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5471108497035079506?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5471108497035079506/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5471108497035079506' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5471108497035079506'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5471108497035079506'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/how-to-start-another-x-session.html' title='How to start another X session'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2916681300079978546</id><published>2009-06-08T10:41:00.000-07:00</published><updated>2009-06-08T10:43:24.248-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Tricks with the Echo command in XP</title><content type='html'>&lt;span style="font-weight: bold;"&gt;rem generate list with echo&lt;/span&gt;&lt;br /&gt;for /l %a in (1,1,9) do echo "station-0%a"&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;rem Generate a file with echo to a room of computers&lt;/span&gt;&lt;br /&gt;for /l %a in (1,1,50) do echo "station-%a" &gt; \\station-%a\c$\myfile.txt&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2916681300079978546?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2916681300079978546/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2916681300079978546' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2916681300079978546'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2916681300079978546'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/tricks-with-echo-command-in-xp.html' title='Tricks with the Echo command in XP'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-174543722932645074</id><published>2009-06-08T10:30:00.000-07:00</published><updated>2009-06-08T10:41:13.493-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Printing from the command line in XP</title><content type='html'>rem Print from command line&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;notepad /p textfile.txt&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-174543722932645074?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/174543722932645074/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=174543722932645074' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/174543722932645074'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/174543722932645074'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/printing-from-command-line-in-xp.html' title='Printing from the command line in XP'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5643711840689245682</id><published>2009-06-07T12:57:00.000-07:00</published><updated>2009-06-07T12:59:27.860-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Java - convert byte array to String</title><content type='html'>&lt;div style='overflow : auto;'&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;int len = (int)c.getLength();&lt;br /&gt;&lt;br /&gt;            if (len &gt; 0) {&lt;br /&gt;                 int actual = 0;&lt;br /&gt;                 int bytesread = 0 ;&lt;br /&gt;                 byte[] data = new byte[len];&lt;br /&gt;                 while ((bytesread != len) &amp;amp;&amp;amp; (actual != -1)) {&lt;br /&gt;                     actual = is.read(data, bytesread, len - bytesread);&lt;br /&gt;                     bytesread += actual;&lt;br /&gt;                    &lt;br /&gt;                 }&lt;br /&gt;&lt;br /&gt;//assuming utf-8 encoding&lt;br /&gt;                 String test = new String(data,0,data.length,"UTF8");&lt;br /&gt;                 System.out.println(test);&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5643711840689245682?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5643711840689245682/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5643711840689245682' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5643711840689245682'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5643711840689245682'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/java-convert-byte-array-to-string.html' title='Java - convert byte array to String'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3675727986161001607</id><published>2009-06-07T12:32:00.000-07:00</published><updated>2011-06-30T15:41:48.590-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Java - how to make an anonymous thread</title><content type='html'>Creating an anonymous thread is pretty easy. If you want to make a thread that performs a simple operation anonymous threads can be convenient.&lt;br /&gt;&lt;br /&gt;Java threads perform their task in the run() function, which is initiated with the start method. &lt;br /&gt;&lt;br /&gt;Here is an example:&lt;br /&gt;&lt;br /&gt;&lt;div style='overflow : auto;'&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;  Thread t = new Thread( new Runnable(){&lt;br /&gt;              public void run(){&lt;br /&gt;                     System.out.println("    do some work");&lt;br /&gt;                         &lt;br /&gt;                     &lt;br /&gt;              }&lt;br /&gt;          });&lt;br /&gt;  &lt;br /&gt;  t.start();&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3675727986161001607?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3675727986161001607/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3675727986161001607' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3675727986161001607'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3675727986161001607'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/java-how-to-make-anonymous-thread.html' title='Java - how to make an anonymous thread'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-9169911444774877003</id><published>2009-06-06T18:07:00.000-07:00</published><updated>2011-06-25T10:34:32.326-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><title type='text'>SVN commands</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Creating a new repository for SVN&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;svnadmin create /path/to/svn/newrepository&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Importing&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;svn --username user import http://svnsite.com/path/to/svn/newrepository -m "initial import"&lt;br /&gt;&lt;br /&gt;#note about importing&lt;br /&gt;#create a local folder called newrepository and put whatever code you want to import into newrepository&lt;br /&gt;#run svn from newrepository&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Permission denied when importing&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;# Do this on the server's svn directory&lt;br /&gt;&lt;br /&gt;sudo chown -R www-data:www-data svn&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-9169911444774877003?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/9169911444774877003/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=9169911444774877003' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/9169911444774877003'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/9169911444774877003'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/svn-commands.html' title='SVN commands'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4361790409349163313</id><published>2009-06-06T17:12:00.000-07:00</published><updated>2009-06-07T12:00:53.211-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='mobile'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Hello world Midlet</title><content type='html'>&lt;div style="overflow: auto;"&gt;&lt;br /&gt;import javax.microedition.lcdui.Display;&lt;br /&gt;import javax.microedition.lcdui.Form;&lt;br /&gt;import javax.microedition.midlet.MIDlet;&lt;br /&gt;import javax.microedition.midlet.MIDletStateChangeException;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;public class LoginScreen extends MIDlet {&lt;br /&gt;&lt;br /&gt;   public LoginScreen() {&lt;br /&gt;       // TODO Auto-generated constructor stub&lt;br /&gt;   }&lt;br /&gt;&lt;br /&gt;   protected void destroyApp(boolean arg0) throws MIDletStateChangeException {&lt;br /&gt;       // TODO Auto-generated method stub&lt;br /&gt;&lt;br /&gt;   }&lt;br /&gt;&lt;br /&gt;   protected void pauseApp() {&lt;br /&gt;       // TODO Auto-generated method stub&lt;br /&gt;&lt;br /&gt;   }&lt;br /&gt;&lt;br /&gt;   protected void startApp() throws MIDletStateChangeException {&lt;br /&gt;       // TODO Auto-generated method stub&lt;br /&gt;     &lt;br /&gt;       Form f = new Form("Login Form");&lt;br /&gt;       Display d = Display.getDisplay(this);&lt;br /&gt;       d.setCurrent(f);&lt;br /&gt;     &lt;br /&gt;       f.append("Hello");&lt;br /&gt;     &lt;br /&gt;   }&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4361790409349163313?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4361790409349163313/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4361790409349163313' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4361790409349163313'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4361790409349163313'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/hello-world-midlet.html' title='Hello world Midlet'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8164794827434003333</id><published>2009-06-06T15:39:00.000-07:00</published><updated>2009-06-06T15:40:28.581-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='design'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Flash tricks - global vars, functions, timers</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Creating global var- &lt;/span&gt;&lt;br /&gt;_global.myvar&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Creating a timer- &lt;/span&gt;&lt;br /&gt;var starttime = getTimer();&lt;br /&gt;var atime=0;&lt;br /&gt;&lt;br /&gt;while (atime &lt; _global.timestop+starttime){&lt;br /&gt;    &lt;br /&gt;    atime = getTimer();&lt;br /&gt;    &lt;br /&gt;    if (_global.conn_state == true){&lt;br /&gt;        break;&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;span style="font-weight: bold;"&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Creating a function- &lt;/span&gt;&lt;br /&gt;function populateJoin(){&lt;br /&gt;&lt;br /&gt;    gamelist.data = _global.currentmsg.split(_global.SEP);&lt;br /&gt;    gamelist.labels = _global.currentmsg.split(_global.SEP);&lt;br /&gt;&lt;br /&gt;    &lt;br /&gt;}&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8164794827434003333?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8164794827434003333/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8164794827434003333' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8164794827434003333'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8164794827434003333'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/flash-tricks-global-vars-functions.html' title='Flash tricks - global vars, functions, timers'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5218969996763762690</id><published>2009-06-06T15:37:00.000-07:00</published><updated>2009-06-06T15:39:28.951-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='design'/><title type='text'>Photoshop Tricks - alpha channels and actions</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Creating an alpha channel (ps cs2)- &lt;/span&gt;&lt;br /&gt;magic lasso outside of the object&lt;br /&gt;inverse select&lt;br /&gt;go to channels&lt;br /&gt;click save selection as channel&lt;br /&gt;Now you can save with the alpha channel&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Creating an action (ps cs2)- &lt;/span&gt;&lt;br /&gt;Click the actions tab&lt;br /&gt;Click new actions and click record&lt;br /&gt;Do what you want to record and press stop&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Automatically start action (ps cs2)- &lt;/span&gt;&lt;br /&gt;go to file -&gt;scripts&lt;br /&gt;click scripts events manager&lt;br /&gt;check the enable events to run scripts/actions&lt;br /&gt;associate your action with an event&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5218969996763762690?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5218969996763762690/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5218969996763762690' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5218969996763762690'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5218969996763762690'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/photoshop-tricks.html' title='Photoshop Tricks - alpha channels and actions'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8815985729422252190</id><published>2009-06-06T13:41:00.000-07:00</published><updated>2009-06-06T15:36:25.674-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='mobile'/><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Java Me Notes</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Links&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Main site&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;http://java.sun.com/javame/index.jsp&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Download&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;http://java.sun.com/products/sjwtoolkit/download.html&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Eclipse plugin&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;http://download.eclipse.org/dsdp/mtj/updates/0.9/stable/&lt;br /&gt;&lt;br /&gt;Need to use eclipse to export jad and jar for the project (which is in deploy)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Conventions&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;startApp() --&gt; like main&lt;br /&gt;&lt;br /&gt;import javax.microedition.lcdui.*; //required to use display&lt;br /&gt;&lt;br /&gt;Display // interface with phone screen&lt;br /&gt;&lt;br /&gt;Form  //set up the screen then attach it to display&lt;br /&gt;&lt;br /&gt;myform.append("some text"); //a label&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8815985729422252190?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8815985729422252190/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8815985729422252190' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8815985729422252190'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8815985729422252190'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/java-me-notes.html' title='Java Me Notes'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-59973370671548705</id><published>2009-06-05T19:05:00.001-07:00</published><updated>2009-06-06T15:50:02.358-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Setting up hsqldb</title><content type='html'>hsqldb is a java based database server&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Install it:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;apt-get install hsqldb-server&lt;br /&gt;&lt;br /&gt;Create the &lt;span style="font-weight: bold;"&gt;server.properties&lt;/span&gt; and &lt;span style="font-weight: bold;"&gt;sqltool.rc&lt;/span&gt; files in your home folder (sample files should be where hsqldb was installed)&lt;br /&gt;&lt;br /&gt;The main jar file is &lt;span style="font-weight: bold;"&gt;/usr/share/java/hsqldb.jar&lt;/span&gt;, which should be in your CLASSPATH when working with hsqldb&lt;br /&gt;&lt;br /&gt;Place a link in /usr/share/tomcat5.5/common/lib if you want to use it with tomcat 5.5.&lt;br /&gt;&lt;br /&gt;There is a swing utility to test and manage the databases.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Starting the server:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;java -cp /path/to/hsqldb.jar org.hsqldb.Server&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Database URL&lt;/span&gt;:&lt;br /&gt;&lt;br /&gt;jdbc:hsqldb:hsql://localhost/mydb&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-59973370671548705?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/59973370671548705/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=59973370671548705' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/59973370671548705'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/59973370671548705'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/setting-up-hsqldb.html' title='Setting up hsqldb'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8778023334794647555</id><published>2009-06-05T14:50:00.000-07:00</published><updated>2009-06-05T14:52:04.613-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><title type='text'>See list of mac file servers on network</title><content type='html'>This is quick way to get a  list of appletalk machines on your network when you only have access to the terminal.&lt;br /&gt;&lt;br /&gt;atlookup&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8778023334794647555?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8778023334794647555/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8778023334794647555' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8778023334794647555'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8778023334794647555'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/see-list-of-mac-file-servers-on-network.html' title='See list of mac file servers on network'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4272478810410499981</id><published>2009-06-05T14:46:00.000-07:00</published><updated>2011-06-25T10:37:52.340-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Set remote desktop from command line</title><content type='html'>reg add "\\computer\hklm\system\currentcontrolset\control\terminal server" /v "fDenyTSConnections" /d 0 /t REG_DWORD /f&lt;br /&gt;&lt;br /&gt;0 is off and 1 is on&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4272478810410499981?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4272478810410499981/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4272478810410499981' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4272478810410499981'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4272478810410499981'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/set-remote-desktop-from-command-line.html' title='Set remote desktop from command line'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1715276722543676140</id><published>2009-06-03T13:19:00.000-07:00</published><updated>2009-06-03T13:22:03.762-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Generate a command window for each iteration of a loop</title><content type='html'>rem This is good for those commands that take a lot of time.&lt;br /&gt;rem Each iteration generates a new cmd window&lt;br /&gt;&lt;br /&gt;for /l %a in (1,1,10) do start cmd /k psexec \\computer-%a time-consuming.exe&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1715276722543676140?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1715276722543676140/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1715276722543676140' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1715276722543676140'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1715276722543676140'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/generate-command-window-for-each.html' title='Generate a command window for each iteration of a loop'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7348847264151866281</id><published>2009-06-03T13:16:00.000-07:00</published><updated>2009-06-03T13:18:07.325-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Force a live update from command line</title><content type='html'>This will perform a silent live update of Symantec Antivirus 10.2&lt;br /&gt;&lt;br /&gt;"c:\Program Files\Symantec AntiVirus\VPDN_LU.exe" /fUpdate /s&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7348847264151866281?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7348847264151866281/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7348847264151866281' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7348847264151866281'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7348847264151866281'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/force-live-update-from-command-line.html' title='Force a live update from command line'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7561608039806829812</id><published>2009-06-03T13:12:00.000-07:00</published><updated>2009-06-03T13:14:35.266-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='vbscript'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Adding a printer with vbscript from a network share</title><content type='html'>rem Add the connection&lt;br /&gt;cscript prnmngr.vbs -ac -p \\server\printer_share&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;rem Set it as a default&lt;br /&gt;cscript prnmngr.vbs -t -p "\\server\printer name"&lt;br /&gt;&lt;br /&gt;rem If you don't know the name&lt;br /&gt;cscript prnmngr.vbs -l&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7561608039806829812?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7561608039806829812/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7561608039806829812' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7561608039806829812'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7561608039806829812'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/adding-printer-with-vbscript-from.html' title='Adding a printer with vbscript from a network share'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3064566874446733315</id><published>2009-06-03T13:04:00.000-07:00</published><updated>2009-06-03T13:09:36.984-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Keeping track of station numbers with a text file</title><content type='html'>rem Usually I keep track of the configurations associated with a station by its mac&lt;br /&gt;rem Without the macs, one can keep track of what configuration to use by using a counter&lt;br /&gt;rem &lt;br /&gt;rem This works well with a network or a flash drive&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;for /f %%a in ('type \\server\share\count.txt') do SET temp=%%a&lt;br /&gt;rem echo %temp%&lt;br /&gt;SET /A temp+=1 &lt;br /&gt;echo %temp% &gt; \\server\share\count.txt&lt;br /&gt;&lt;br /&gt;rem The counts of count.txt is simply a number and can be used in a script&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3064566874446733315?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3064566874446733315/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3064566874446733315' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3064566874446733315'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3064566874446733315'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/keeping-track-of-station-numbers-with.html' title='Keeping track of station numbers with a text file'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1687134857088343617</id><published>2009-06-03T05:32:00.000-07:00</published><updated>2009-06-03T05:34:55.813-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Adding an extension to a bunch of files</title><content type='html'>#I made a bunch of text files for Windows, but XP cannot open them without an extension&lt;br /&gt;#This was a quick fix&lt;br /&gt;&lt;br /&gt;find . -type f -exec mv {} {}.txt \;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1687134857088343617?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1687134857088343617/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1687134857088343617' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1687134857088343617'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1687134857088343617'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/adding-extension-to-bunch-of-files.html' title='Adding an extension to a bunch of files'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5282338756390058551</id><published>2009-06-02T17:28:00.000-07:00</published><updated>2009-06-03T15:16:48.216-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><title type='text'>Installing Apache Tomcat  5.5</title><content type='html'>#make sure you add unstable entries to sources.list&lt;br /&gt;apt-get install sun-java6-jdk&lt;br /&gt;&lt;br /&gt;apt-get install tomcat5.5&lt;br /&gt;apt-get install tomcat5.5-admin&lt;br /&gt;apt-get install tomcat5.5-webapps&lt;br /&gt;&lt;br /&gt;$CATALINA_HOME/webapps/ROOT/index.jsp&lt;br /&gt;/usr/share/tomcat5.5-webapps/ROOT/index.jsp&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#it will be listening on port 8180&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5282338756390058551?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5282338756390058551/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5282338756390058551' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5282338756390058551'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5282338756390058551'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/installing-apache-tomcat-55.html' title='Installing Apache Tomcat  5.5'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1625919965796606909</id><published>2009-06-02T15:47:00.000-07:00</published><updated>2009-06-02T17:11:45.479-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><title type='text'>Debian package manager</title><content type='html'>#useful Debian/Ubuntu package commands&lt;br /&gt;&lt;br /&gt;apt-get install package&lt;br /&gt;apt-get remove package&lt;br /&gt;apt-get update #good for updating your database after editing sources.list&lt;br /&gt;apt-cache search search_string&lt;br /&gt;&lt;br /&gt;dpkg --list&lt;br /&gt;dpkg --install program.deb&lt;br /&gt;dpkg --remove program&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#Sometimes you have to add this to /etc/apt/sources.list&lt;br /&gt;# etch is a version of Debian, replace with your version&lt;br /&gt;&lt;br /&gt;deb http://security.debian.org/ etch/updates main contrib&lt;br /&gt;deb-src http://security.debian.org/ etch/updates main contrib&lt;br /&gt;&lt;br /&gt;deb http://ftp.debian.org/debian/ etch main&lt;br /&gt;deb-src http://ftp.debian.org/debian/ etch main&lt;br /&gt;&lt;br /&gt;#these are good for install outside packages like java&lt;br /&gt;&lt;br /&gt;deb http://ftp.debian.org/debian/ unstable non-free&lt;br /&gt;deb-src http://ftp.debian.org/debian/ unstable non-free&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1625919965796606909?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1625919965796606909/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1625919965796606909' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1625919965796606909'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1625919965796606909'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/debian-package-manager.html' title='Debian package manager'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4719189694447432420</id><published>2009-06-02T11:02:00.000-07:00</published><updated>2009-06-02T11:03:31.670-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Power configuration from command line with xp</title><content type='html'>powercfg /setactive "always on"&lt;br /&gt;&lt;br /&gt;powercfg /query&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4719189694447432420?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4719189694447432420/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4719189694447432420' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4719189694447432420'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4719189694447432420'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/power-configuration-from-command-line.html' title='Power configuration from command line with xp'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7673900540464041156</id><published>2009-06-02T10:46:00.000-07:00</published><updated>2009-06-02T10:48:12.074-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tools'/><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>net time commands</title><content type='html'>net time (time from domain server)&lt;br /&gt;&lt;br /&gt;net time /querysntp &lt;br /&gt;&lt;br /&gt;net time /set \\another_pc&lt;br /&gt;&lt;br /&gt;net time /setsntp:time.apple.com&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7673900540464041156?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7673900540464041156/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7673900540464041156' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7673900540464041156'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7673900540464041156'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/net-time-commands.html' title='net time commands'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1016843585485689045</id><published>2009-06-01T15:53:00.000-07:00</published><updated>2011-06-30T15:53:20.005-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='vbscript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Change a computer name with vbscript</title><content type='html'>Scripting the changing of computer names in windows is straight-forward with a vbscript. &lt;br /&gt;&lt;br /&gt;You can change a computer via the registry, so this is the approach used here.&lt;br /&gt;&lt;br /&gt;Set the computer name you want in the sNewName variable.&lt;br /&gt;&lt;br /&gt;&lt;div style ="overflow : auto ; "&gt;&lt;br /&gt;&lt;br /&gt;sNewName = "new_pc_name"&lt;br /&gt;&lt;br /&gt;Set oShell = CreateObject ("WSCript.shell") &lt;br /&gt; &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;sCCS = "HKLM\SYSTEM\CurrentControlSet\" &lt;br /&gt;&lt;br /&gt;sTcpipParamsRegPath = sCCS &amp; "Services\Tcpip\Parameters\" &lt;br /&gt;&lt;br /&gt;sCompNameRegPath = sCCS &amp; "Control\ComputerName\" &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;With oShell &lt;br /&gt;&lt;br /&gt;.RegDelete sTcpipParamsRegPath &amp; "Hostname" &lt;br /&gt;&lt;br /&gt;.RegDelete sTcpipParamsRegPath &amp; "NV Hostname" &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;.RegWrite sCompNameRegPath &amp; "ComputerName\ComputerName", sNewName &lt;br /&gt;&lt;br /&gt;.RegWrite sCompNameRegPath &amp; "ActiveComputerName\ComputerName", sNewName &lt;br /&gt;&lt;br /&gt;.RegWrite sTcpipParamsRegPath &amp; "Hostname", sNewName &lt;br /&gt;&lt;br /&gt;.RegWrite sTcpipParamsRegPath &amp; "NV Hostname", sNewName &lt;br /&gt;&lt;br /&gt;End With ' oShell &lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1016843585485689045?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1016843585485689045/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1016843585485689045' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1016843585485689045'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1016843585485689045'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/change-computer-name-with-vbscript.html' title='Change a computer name with vbscript'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7584100067154774022</id><published>2009-06-01T15:46:00.000-07:00</published><updated>2009-06-01T15:57:59.713-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='vbscript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>VBScript tricks : no logo, filesystem, control blocks, argument</title><content type='html'>&lt;div styles='overflow : auto;'&gt;&lt;br /&gt;'When running from the console, here is how to hide the logo&lt;br /&gt;&lt;br /&gt;cscript //Nologo myscript.vbs&lt;br /&gt;&lt;br /&gt;'How to reference an argument&lt;br /&gt;WScript.Arguments.Item(0)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;'Here is how to read a file&lt;br /&gt;&lt;br /&gt;set f = fso.opentextfile(source, 1,false)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;if fso.fileexists(source) then&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  while not f.atendofstream&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;&lt;br /&gt;   inputline = f.readline&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;   msgbox inputline&lt;br /&gt;&lt;br /&gt;  wend&lt;br /&gt;&lt;br /&gt;end if&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7584100067154774022?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7584100067154774022/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7584100067154774022' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7584100067154774022'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7584100067154774022'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/vbscript-tricks-no-logo-filesystem.html' title='VBScript tricks : no logo, filesystem, control blocks, argument'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-6846218802792995480</id><published>2009-06-01T15:42:00.000-07:00</published><updated>2009-06-01T15:43:51.328-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Inserting a blank line with sed</title><content type='html'>#I found this to be a bit tricky&lt;br /&gt;&lt;br /&gt;sed -e '/pattern/i\&lt;br /&gt;\ # &lt;-- this is the key&lt;br /&gt;' input_file &gt; output_file&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-6846218802792995480?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/6846218802792995480/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=6846218802792995480' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6846218802792995480'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/6846218802792995480'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/06/inserting-blank-line-with-sed.html' title='Inserting a blank line with sed'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-9107302059989729113</id><published>2009-05-30T21:42:00.000-07:00</published><updated>2011-06-25T10:38:21.473-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>awk example using arrays, the split() function, and regex</title><content type='html'>#record format&lt;br /&gt;&lt;br /&gt;Request: 10&lt;br /&gt;As Of: 05/27/2009 1:34:58 pm&lt;br /&gt;Irrevelant Data ...&lt;br /&gt;Summary:  Virus on PC.&lt;br /&gt;Description:  Virus on PC.&lt;br /&gt;&lt;br /&gt;Request: 11&lt;br /&gt;As Of: 05/27/2009 1:34:58 pm&lt;br /&gt;Irrevelant Data...&lt;br /&gt;Summary:  room1 several computers in a row are freezing up and student...&lt;br /&gt;Description:  room1 several computers in a row are freezing up and students have to reboot.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;awk -v pat1="room1" -v pat2="freezing|crash" 'BEGIN { RS=""; FS="Summary"; i=0; j=0; k=0 } {\&lt;br /&gt; i=i+1; \&lt;br /&gt; field1=$1; \&lt;br /&gt; split(field1,sub_fields,":"); \&lt;br /&gt; request=sub_fields[1]; \&lt;br /&gt; the_date=sub_fields[4]; \&lt;br /&gt; if ($2 ~ pat1){  \&lt;br /&gt;  k=k+1; \&lt;br /&gt;  if ($2 ~ pat2){ \&lt;br /&gt;   j=1+j; \&lt;br /&gt;   print "***Record***", request, the_date; print " ---Start Data---", $2; } } \&lt;br /&gt;} END { print "Processed, ", i, ",num of lab matches,", k,", records num of keywords matches: ,", j }'  requests&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#Output&lt;br /&gt;&lt;br /&gt;***Record*** Request  05/27/2009 1&lt;br /&gt;---Start Data--- :  room1 several computers in a row are freezing up and student...&lt;br /&gt;Description:  room1 several computers in a row are freezing up and students have to reboot.&lt;br /&gt;Processed,  2 ,num of lab matches, 1 , records num of keywords matches: , 1&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-9107302059989729113?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/9107302059989729113/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=9107302059989729113' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/9107302059989729113'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/9107302059989729113'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/awk-example-using-arrays-split-function.html' title='awk example using arrays, the split() function, and regex'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-578128218622083113</id><published>2009-05-29T21:40:00.000-07:00</published><updated>2009-05-29T21:44:02.546-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Removing carriage returns with sed</title><content type='html'>sed -e s/$'\r'/\ /g  input_file # remove carriage returns&lt;br /&gt;&lt;br /&gt;sed -e 's/\n/ /g'  input_file # remove newlines&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-578128218622083113?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/578128218622083113/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=578128218622083113' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/578128218622083113'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/578128218622083113'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/removing-carriage-returns-with-sed.html' title='Removing carriage returns with sed'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1617001792822430402</id><published>2009-05-29T10:49:00.001-07:00</published><updated>2009-05-29T10:50:03.914-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Insert text before a pattern with sed</title><content type='html'>cat some_file | sed '/pattern/i\&lt;br /&gt;text to insert&lt;br /&gt;' &gt; output_file&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1617001792822430402?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1617001792822430402/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1617001792822430402' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1617001792822430402'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1617001792822430402'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/insert-text-before-pattern-with-sed.html' title='Insert text before a pattern with sed'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1657297009207919583</id><published>2009-05-29T10:24:00.000-07:00</published><updated>2011-06-25T10:34:50.204-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><title type='text'>Remove empty lines with vi</title><content type='html'>In ex mode:&lt;br /&gt;&lt;br /&gt;:1,$s/^$//&lt;br /&gt;&lt;br /&gt;Sometimes you need to do this too:&lt;br /&gt;&lt;br /&gt;:1,$s/^\n//&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;May be able to do this:&lt;br /&gt;&lt;br /&gt;:1,$s/^[\n$]//&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1657297009207919583?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1657297009207919583/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1657297009207919583' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1657297009207919583'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1657297009207919583'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/remove-empty-lines-with-vi.html' title='Remove empty lines with vi'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-789730108500609493</id><published>2009-05-29T10:13:00.000-07:00</published><updated>2011-06-25T10:35:02.381-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><title type='text'>Show special characters in vi</title><content type='html'>:set list&lt;br /&gt;&lt;br /&gt;# see control chars (tabstops, control characters, etc)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-789730108500609493?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/789730108500609493/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=789730108500609493' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/789730108500609493'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/789730108500609493'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/show-control-characters-in-vi.html' title='Show special characters in vi'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7317835532693152436</id><published>2009-05-29T09:53:00.001-07:00</published><updated>2011-06-25T10:38:29.711-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Example of processing multiline records with awk</title><content type='html'>Processing multiline records is tricky. It is easier to use blank lines as record separators. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#example records&lt;br /&gt;ink1     4.99&lt;br /&gt;     red&lt;br /&gt;&lt;br /&gt;ink2     5.99&lt;br /&gt;     yellow&lt;br /&gt;&lt;br /&gt;awk ' BEGIN { RS=""; FS="    "} { r1=$1; r2=$2; r3=$3; print "***Record***"  r1 " " r2 " " r3 }'  inks&lt;br /&gt;&lt;br /&gt;#What it prints out&lt;br /&gt;***Record***ink1  4.99&lt;br /&gt;  red&lt;br /&gt;***Record***ink2  5.99&lt;br /&gt;  yellow&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7317835532693152436?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7317835532693152436/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7317835532693152436' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7317835532693152436'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7317835532693152436'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/example-of-processing-multiline-records.html' title='Example of processing multiline records with awk'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-1710362003455407336</id><published>2009-05-28T17:27:00.000-07:00</published><updated>2009-06-06T15:41:23.017-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sysadmin'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Creating a mysql user and granting privileges</title><content type='html'>//standard way of creating a user&lt;br /&gt;&lt;br /&gt;CREATE USER 'monty'@'localhost' IDENTIFIED BY 'some_pass';&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;//Creating a user and granting privileges:&lt;br /&gt;&lt;br /&gt;GRANT ALL PRIVILEGES ON table.* TO 'user'@'localhost' identified by 'password' &lt;br /&gt;&lt;br /&gt;//Show privileges for a user:&lt;br /&gt;&lt;br /&gt;show grants for 'user'@'localhost'&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-1710362003455407336?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/1710362003455407336/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=1710362003455407336' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1710362003455407336'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/1710362003455407336'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/creating-mysql-user-and-granting.html' title='Creating a mysql user and granting privileges'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2676261669834711875</id><published>2009-05-28T17:11:00.000-07:00</published><updated>2011-06-25T10:32:52.229-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Install Windows nic driver on Linux</title><content type='html'>#Download ndiswrapper&lt;br /&gt;&lt;br /&gt;make #this will install the kernel module (after compiling)&lt;br /&gt;modprobe ndiswrapper&lt;br /&gt;ndiswrapper -i driver.inf&lt;br /&gt;ndiswrapper -m #generate modprobe alias for ndiswrapper&lt;br /&gt;#restart&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#Check installed drivers:&lt;br /&gt;&lt;br /&gt;ndiswrapper -l&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2676261669834711875?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2676261669834711875/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2676261669834711875' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2676261669834711875'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2676261669834711875'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/install-windows-nic-driver-on-linux.html' title='Install Windows nic driver on Linux'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8705017071405584600</id><published>2009-05-28T10:44:00.000-07:00</published><updated>2009-06-06T12:39:24.304-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Showing a decimal expansion with bc</title><content type='html'>#3 digits after the decimal place&lt;br /&gt;echo "scale=3; 41.0 / 939.0" | bc&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8705017071405584600?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8705017071405584600/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8705017071405584600' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8705017071405584600'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8705017071405584600'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/showing-numbers-less-than-1-with-bc.html' title='Showing a decimal expansion with bc'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-554990451524429813</id><published>2009-05-27T10:08:00.000-07:00</published><updated>2011-06-25T10:38:38.143-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='unix'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>awk script to generate count of each program</title><content type='html'>#csv of format:&lt;br /&gt;#the_program, any_data, any_data, ....&lt;br /&gt;#&lt;br /&gt;#this script counts number of repetitions of a program&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;cat program-list.csv | awk -F',' '/[a-zA-Z0-9]+/{print $1}' | sort | uniq -c&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-554990451524429813?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/554990451524429813/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=554990451524429813' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/554990451524429813'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/554990451524429813'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/awk-script-to-generate-count-of-each.html' title='awk script to generate count of each program'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-3149047010466106306</id><published>2009-05-26T17:07:00.000-07:00</published><updated>2011-06-25T10:36:54.541-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='design'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Create a dojo dialog widget</title><content type='html'>&lt;textarea cols="50"&gt;&lt;!-- How to create a dojo dialog widget --&gt;&lt;div dojotype="dijit.Dialog" id="dialog1" title="test dialog" href="test.html"&gt;&lt;/div&gt;&lt;/textarea&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-3149047010466106306?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/3149047010466106306/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=3149047010466106306' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3149047010466106306'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/3149047010466106306'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/create-dojo-dialog-widget.html' title='Create a dojo dialog widget'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4741157298574674690</id><published>2009-05-26T12:35:00.000-07:00</published><updated>2009-05-26T12:37:17.587-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Create Messagebox / popup for Java</title><content type='html'>//Assuming that the current object is a JFrame:&lt;br /&gt;&lt;br /&gt;JOptionPane.showMessageDialog(this, "Some Message");&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4741157298574674690?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4741157298574674690/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4741157298574674690' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4741157298574674690'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4741157298574674690'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/create-messagebox-popup-for-java.html' title='Create Messagebox / popup for Java'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-2425104829489244547</id><published>2009-05-25T16:16:00.000-07:00</published><updated>2011-06-25T10:39:09.544-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Php declare a constant</title><content type='html'>define("CONSTANT", "Hello world.");&lt;br /&gt;echo CONSTANT; // outputs "Hello world."&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-2425104829489244547?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/2425104829489244547/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=2425104829489244547' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2425104829489244547'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/2425104829489244547'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/05/php-declare-constant.html' title='Php declare a constant'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7819167655509920034</id><published>2009-04-20T18:53:00.000-07:00</published><updated>2009-06-01T15:57:34.609-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>For loop of death</title><content type='html'>This is a way to somewhat defend yourself when a process keeps on respawning itself and won't go away. This happens quite a bit when XP gets infiltrated by malware.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="overflow : auto;"&gt;&lt;br /&gt;&lt;br /&gt;for /l %a in (1,1,1000000) do taskkill /im malware.exe /f&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7819167655509920034?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7819167655509920034/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7819167655509920034' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7819167655509920034'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7819167655509920034'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/04/for-loop-of-death.html' title='For loop of death'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4012256787205798814</id><published>2009-04-20T05:59:00.000-07:00</published><updated>2009-06-01T15:59:38.521-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='vbscript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Universal scripted uninstall (XP)</title><content type='html'>Given the displayname value, this vbscript will go and find it in the registry and uninstall the corresponding program.&lt;br /&gt;&lt;br /&gt;This is where it searches:&lt;br /&gt;&lt;br /&gt;hklm\software\microsoft\windows\currentversion\uninstall&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="overflow:auto"&gt;&lt;br /&gt;' arg 1 - displayname&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;if (wscript.arguments.count &gt; 0 ) then&lt;br /&gt;&lt;br /&gt; set shell = wscript.createobject("wscript.shell")&lt;br /&gt; strcmd = "reg query hklm\software\microsoft\windows\currentversion\uninstall /s"&lt;br /&gt;&lt;br /&gt; set oexec = shell.exec(strcmd)&lt;br /&gt;&lt;br /&gt; temp = 0&lt;br /&gt; parent = ""&lt;br /&gt;&lt;br /&gt; do while not oexec.stdout.atendofstream&lt;br /&gt;&lt;br /&gt;  strline = oexec.stdout.readline&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  if len(strline) &gt; 0 then&lt;br /&gt;   a=split(strline,vbtab)&lt;br /&gt;   if mid(trim(a(0)),1,4) = "HKEY" then&lt;br /&gt;    b = split(trim(a(0)),"\")&lt;br /&gt;    parent = b(ubound(b))&lt;br /&gt;    temp = 1&lt;br /&gt;   end if   &lt;br /&gt;   alen = ubound(a) + 1&lt;br /&gt;   if alen &gt;= 3 then&lt;br /&gt;    if trim(a(0)) = "DisplayName" and trim(a(2)) = wscript.arguments(0) and temp = 1 then&lt;br /&gt;     wscript.echo "msiexec /x " &amp; parent &amp; " /qn"&lt;br /&gt;     temp = 0&lt;br /&gt;     shell.exec("msiexec /x " &amp; parent &amp; " /qn")&lt;br /&gt;     exit do&lt;br /&gt;    end if&lt;br /&gt;        &lt;br /&gt;   end if&lt;br /&gt;  end if&lt;br /&gt; loop&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;end if&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4012256787205798814?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4012256787205798814/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4012256787205798814' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4012256787205798814'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4012256787205798814'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/04/universal-scripted-uninstall-xp.html' title='Universal scripted uninstall (XP)'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-7564398534263671112</id><published>2009-04-19T18:29:00.000-07:00</published><updated>2011-06-25T10:37:05.671-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='design'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Solution to generating markers along a route at  a regular interval</title><content type='html'>I found this neat javascript extension for the google map api. Here is the link:&lt;br /&gt;&lt;br /&gt;http://econym.org.uk/gmap/epoly.htm&lt;br /&gt;&lt;br /&gt;You specify the distance and give it a polyline and it returns an array of points along the route.&lt;br /&gt;&lt;br /&gt;&lt;pre style="overflow:auto"&gt;&lt;br /&gt;&lt;br /&gt;map.setCenter(new GLatLng(42.351505,-71.094455), 15);&lt;br /&gt;    var directionsPanel = document.getElementById("directions_div");&lt;br /&gt;    var directions = new GDirections(map, directionsPanel);&lt;br /&gt;    var address = "from: trenton, nj to: philadelphia, pa";&lt;br /&gt;&lt;br /&gt;    directions.load(new_address);&lt;br /&gt;  if (directions == null){&lt;br /&gt;    alert("Error: directions object is null");&lt;br /&gt;    return;&lt;br /&gt;   }&lt;br /&gt;   &lt;br /&gt;   var pl = directions.getPolyline();&lt;br /&gt;   &lt;br /&gt;   if (pl == null){&lt;br /&gt;    alert("Error: polyline object is null");&lt;br /&gt;    return;&lt;br /&gt;   }&lt;br /&gt;   &lt;br /&gt;   var points = pl.GetPointsAtDistance(1609.344);&lt;br /&gt;&lt;br /&gt;   if (points == null){&lt;br /&gt;    return;     &lt;br /&gt;   }&lt;br /&gt;   &lt;br /&gt;   for (var i=0; i&lt;points.length;&gt;&lt;br /&gt;    map.addOverlay(new GMarker(points[i]));&lt;br /&gt;   }&lt;br /&gt;&lt;/points.length;&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-7564398534263671112?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/7564398534263671112/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=7564398534263671112' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7564398534263671112'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/7564398534263671112'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2009/04/solution-to-generating-markers-along.html' title='Solution to generating markers along a route at  a regular interval'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-366577553317671883</id><published>2008-12-19T15:02:00.001-08:00</published><updated>2011-06-25T10:34:04.265-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Viruses are back again!</title><content type='html'>Just when you thought XP Antivirus 2008 died out, enter AntiSpyware 2009. This piece of crap gets on your machine by screwing up internet explorer and the startup environment. The damn thing protects itself even in safe mode. I'm not sure how it does this; usually this is done with winlogon.exe, but the winlogon registry key seemed to be clean. We've just been reghosting the machine. Watch where you click! When you see a dialog box about spyware (and it's definitely not your antivirus software) restart your machine (this dialog box is from internet explorer).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-366577553317671883?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/366577553317671883/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=366577553317671883' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/366577553317671883'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/366577553317671883'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2008/12/viruses-are-back-again.html' title='Viruses are back again!'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-8364724693322444029</id><published>2008-12-19T14:56:00.001-08:00</published><updated>2011-06-25T10:33:01.611-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mobile'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Blackberry desktop manager</title><content type='html'>Working with the BDM has not been a general pleasure for me and other technicians where I work. It doesn't sync all the time, most likely due to corrupt organizer data and/or buggy software. The weird thing is that it was working kind alright when we had an Exchange server, but it got crappy when we migrated to a MAPI connector with Sun. I got it syncing by installing the exchange redirector BDM (we're still using outlook) and disabling redirection?! In the process of stumbling on this, I became familiar with just about every troubleshooting BB trick. Fun!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-8364724693322444029?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/8364724693322444029/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=8364724693322444029' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8364724693322444029'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/8364724693322444029'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2008/12/blackberry-desktop-manager.html' title='Blackberry desktop manager'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5321279777400433119</id><published>2008-08-27T15:57:00.000-07:00</published><updated>2011-06-25T10:31:54.451-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cmd'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>IT Rant II : Disk Imaging</title><content type='html'>If you have many computers, then you probably dread the time of year where you have to refresh their configurations. There are so many solutions available, but the ones that work and are simple to use are few and far between. Ghost 11 is not one of those programs, and neither is NetInstall for OS X 10.4.11. Ghost 11 would not clone Windows x64 nor regular XP sp3 (it worked for me before with Vista). I have gotten NetInstall to work in the past, but there was some issue with System Image utility failing to copy files. It looks like Apple has done a half ass job of updating OS X once again. I should have upgraded to Leopard server... I guess it's back to my reliable friend disk utility for restores until that happens.&lt;br /&gt;&lt;br /&gt;Recently, my disk masters have reached very great sizes -- 100GB and up. This becomes a matter of give and take, because I want to do all my setups on the master. However, by doing so, I am creating images that are far too large. If I have sample files and/or programs that can be copied later, then this is the thing to do. I can copy the files with for loops like so:&lt;br /&gt;&lt;br /&gt;Mac -&lt;br /&gt;for ((i=1;i&lt;21;i++))&lt;br /&gt;do&lt;br /&gt;scp somefile mylogon@station${i}.local:samples #make sure you copy the public key from ssh-keygen&lt;br /&gt;done # to each station in ~/.ssh&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Windows-&lt;br /&gt;for /l %a in (1,1,20) do copy samplefile.txt \\station%a\c$\samples&lt;br /&gt;&lt;br /&gt;There are all kinds of ways to simplify network tasks, but this still doesn't give us an excuse to procrastinate when building disk images. Try and do everything that is to be cloned in the master. Also, try to save space.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5321279777400433119?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5321279777400433119/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5321279777400433119' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5321279777400433119'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5321279777400433119'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2008/08/it-rant-ii-imaging.html' title='IT Rant II : Disk Imaging'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-5371317797107974121</id><published>2008-08-01T16:23:00.000-07:00</published><updated>2008-08-31T22:00:53.545-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='vbscript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='scripting'/><title type='text'>Yes, you can script anything I - vbscript: sendkeys, stdout</title><content type='html'>What happens when you want to automate some configuration and you can't find the command line equivalent, the registry setting eludes you, and the apis to do the task seem too elaborate? Well just do it with it a few key strokes, but have vbscript do the operations for you. It's like doing a macro in excel or your favorite application.&lt;br /&gt;&lt;br /&gt;Check out this &lt;a href="http://msdn.microsoft.com/en-us/library/8c6yea83(VS.85).aspx"&gt;link&lt;/a&gt; for the sendkeys method in wsh.&lt;br /&gt;&lt;br /&gt;A lot times I am frustrated by trying to get Windows to act like Unix. When I want to do some string processing, it seems easier just to use vbscript and call the commandline from there. You can collect the information from stdout with the WScript.Shell object.&lt;br /&gt;&lt;br /&gt;Check out this &lt;a href="http://www.experts-exchange.com/Programming/Misc/Q_21890965.html"&gt;example&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-5371317797107974121?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/5371317797107974121/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=5371317797107974121' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5371317797107974121'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/5371317797107974121'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2008/08/yes-you-script-anything.html' title='Yes, you can script anything I - vbscript: sendkeys, stdout'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8266865608792123597.post-4790089888077614412</id><published>2008-08-01T16:09:00.000-07:00</published><updated>2011-06-25T10:34:16.213-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>IT Rant I - Viruses and malware running amok</title><content type='html'>Every week I find myself cleaning off someone's machine. Typically, the cleaning process starts with booting into safe mode and running an antivirus scan. Also, cleaning out the registry and startup regions with autoruns. These are steps that may be followed after trying a system restore. The problem with a system restore is that you have to run an antivirus scan anyway, just to be sure.&lt;br /&gt;&lt;br /&gt;Recently, I met some particularly annoying viruses such as Graybird, XP Security Center (also known as XP Antivirus 2008), and some others. I'm not sure which one it was, but it removed the svchost. I couldn't use the taskbar, start menu, read event log messages, copy files, or start internet explorer. It looks like the dllcache was emptied too, since sfc /scannow didn't work. It seems Windows users should just be locked down. Let's just give them a simple finder shell.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8266865608792123597-4790089888077614412?l=voicerlyeh.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://voicerlyeh.blogspot.com/feeds/4790089888077614412/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8266865608792123597&amp;postID=4790089888077614412' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4790089888077614412'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8266865608792123597/posts/default/4790089888077614412'/><link rel='alternate' type='text/html' href='http://voicerlyeh.blogspot.com/2008/08/viruses-and-malmare-running-amok.html' title='IT Rant I - Viruses and malware running amok'/><author><name>james</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
