<?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-24582276</id><updated>2012-02-16T15:03:41.325+08:00</updated><category term='wcf'/><category term='c#'/><category term='visual studio'/><category term='xml'/><category term='vb6'/><category term='acrobat'/><category term='office 2007'/><category term='iis'/><category term='javascript'/><category term='programming tools'/><category term='activex'/><category term='internet explorer'/><category term='ajax'/><category term='obfuscator'/><category term='programming'/><category term='xpath'/><category term='microsoft'/><category term='multithreading'/><category term='windows'/><category term='IT news'/><category term='dotnet'/><category term='open source'/><category term='pdf'/><title type='text'>Alexis' Blog</title><subtitle type='html'>main(k){float i,j,r,x,y=-16;
while(puts(""),y++&lt;15)
for(x=0;x++&lt;84;putchar(".:-;!/&gt;)|&amp;IH%*#"[k&amp;15]))
for(i=k=r=0;j=r*r-i*i-2+x/25,i=2*r*i+y/10,
j*j+i*i&lt;11&amp;&amp;k++&lt;111;r=j);}/* Mandelbrot in ASCII. */</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>44</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-24582276.post-6965024067614787656</id><published>2009-06-15T13:34:00.002+08:00</published><updated>2009-06-15T13:41:50.385+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='multithreading'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='c#'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>MessageBox MultiThreading</title><content type='html'>In one of my WinForms projects, I needed to show a MessageBox dialog. Given the architecture of the program, showing a MessageBox would freeze the window. The user would have to press the 'Alt' key from the parent window to show the MessageBox, and click OK.&lt;br /&gt;&lt;br /&gt;As a solution, I multithread the calling of MessageBox.Show(). Nothing new here, but it works.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-6965024067614787656?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/6965024067614787656/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=6965024067614787656' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6965024067614787656'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6965024067614787656'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2009/06/messagebox-multithreading.html' title='MessageBox MultiThreading'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-55043693394839330</id><published>2009-03-09T14:35:00.009+08:00</published><updated>2009-03-09T14:58:42.919+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='visual studio'/><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='c#'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><title type='text'>Quick Update plus Weird VS2005 Error</title><content type='html'>Quick Update: I moved on to another company since a couple of months ago. Had no time to update this blog for almost a year!&lt;br /&gt;&lt;br /&gt;Now, the weird error: I wasn't able to do searches in VS2005. Many of you may have already encountered this error, and I've encountered this a few times already. Thus, I am writing this down so I won't have to google my solution again.&lt;br /&gt;&lt;br /&gt;The error in the Find Results window was:&lt;br /&gt;&lt;em&gt;“No files were found to look in. Find was stopped in progress.”&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;Apparently the solution was to press &lt;strong&gt;Ctrl-Scroll Lock&lt;/strong&gt;. This is the most difficult solution to find without the internet!&lt;br /&gt;&lt;br /&gt;Microsoft has a &lt;a href="http://msdn.microsoft.com/en-us/library/z613zk0e(VS.80).aspx"&gt;fancier solution&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-55043693394839330?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://vidmar.net/weblog/archive/2007/04/17/Strangest-error-No-files-were-found-to-look-in.-Find.aspx' title='Quick Update plus Weird VS2005 Error'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/55043693394839330/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=55043693394839330' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/55043693394839330'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/55043693394839330'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2009/03/quick-update-plus-weird-vs2005-error.html' title='Quick Update plus Weird VS2005 Error'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-4555505623348654684</id><published>2008-04-09T14:02:00.003+08:00</published><updated>2008-04-09T14:24:32.458+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='visual studio'/><category scheme='http://www.blogger.com/atom/ns#' term='programming tools'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='c#'/><category scheme='http://www.blogger.com/atom/ns#' term='obfuscator'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Free .Net Obfuscator</title><content type='html'>I've stumbled upon a &lt;a href="http://www.foss.kharkov.ua/g1/projects/eazfuscator/dotnet/"&gt;free .Net obfuscator&lt;/a&gt;--Eazfuscator.NET. So far, it works well for my purposes. Most obfuscators are costly--ranging from $200 to $2000! But this one is freeware and it works better than the free one bundled with Visual Studio 2005.&lt;br /&gt;&lt;br /&gt;It is free and easy to use!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-4555505623348654684?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.foss.kharkov.ua/g1/projects/eazfuscator/dotnet/' title='Free .Net Obfuscator'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/4555505623348654684/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=4555505623348654684' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/4555505623348654684'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/4555505623348654684'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2008/04/free-net-obfuscator.html' title='Free .Net Obfuscator'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116070977329410159</id><published>2008-04-08T20:00:00.004+08:00</published><updated>2008-04-08T21:18:46.628+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='visual studio'/><category scheme='http://www.blogger.com/atom/ns#' term='pdf'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='c#'/><category scheme='http://www.blogger.com/atom/ns#' term='acrobat'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><category scheme='http://www.blogger.com/atom/ns#' term='activex'/><title type='text'>Printing PDF Using WebBrowser Control in .Net 2.0</title><content type='html'>Okay, after almost a year and an offshore assignment, I finally had a chance to update this blog.&lt;br /&gt;&lt;br /&gt;I was developing a .Net 2.0 C# windows application wherein I basically have to print &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;PDF&lt;/span&gt; files from a Windows application. I tried to use the Adobe Acrobat Reader &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;ActiveX&lt;/span&gt; object embedded in my form to preview and print &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;PDF&lt;/span&gt; documents. It worked fine; I just have to import the COM component and Visual Studio will do most of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;Interop&lt;/span&gt; work for me. I then have to locate the file and load it to the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;AxAcroPDF&lt;/span&gt; control:&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;axAcroPDF&lt;/span&gt;1.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;LoadFile&lt;/span&gt;(&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;pdfFileName&lt;/span&gt;);&lt;/span&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;I'd then delete the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;PDF&lt;/span&gt; file immediately afterwards to somehow obscure it from the user. The &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_9"&gt;ActiveX&lt;/span&gt; object seems to save it in memory such that I can make a call like:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_10"&gt;axAcroPDF&lt;/span&gt;1.Print();&lt;/span&gt;&lt;/blockquote&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;...and all went smoothly. But when I ran it on another machine with the most recent version of Acrobat (8.1.2), I got an E_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_11"&gt;NOINTERFACE&lt;/span&gt; exception. After much research, I then decided to use a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_12"&gt;WebBrowser&lt;/span&gt; .Net 2.0 control instead. Thus, my codes looked like so:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_13"&gt;webBrowser&lt;/span&gt;1.Navigate(&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_14"&gt;pdfFileName&lt;/span&gt;);&lt;/span&gt;&lt;/blockquote&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;...assuming of course that the user has a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_15"&gt;PDF&lt;/span&gt; reader installed and integrated into his web browser. This is a much easier alternative than to using &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_16"&gt;unmanaged&lt;/span&gt; code. However, it does not go away without problems. When I try to call:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;blockquote&gt;&lt;span style="font-size:85%;"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_17"&gt;webBrowser&lt;/span&gt;1.Print();&lt;/span&gt;&lt;/blockquote&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;I get nothing. I can't seem to force the browser to print its &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_18"&gt;PDF&lt;/span&gt; contents. To keep the long story short, I had to tinker with the underlying &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_19"&gt;ActiveX&lt;/span&gt; object of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_20"&gt;WebBrowser&lt;/span&gt; control. First, I needed a reference to &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_21"&gt;shdocvw&lt;/span&gt;.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_22"&gt;dll&lt;/span&gt; (windows system32 directory). Then, I did something like:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;object n = null;     &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_23"&gt;SHDocVw&lt;/span&gt;.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_24"&gt;WebBrowser&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_25"&gt;wb&lt;/span&gt; = (SHDocVw.WebBrowser)webBrowser1.ActiveXInstance; &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;wb.ExecWB(OLECMDID.OLECMDID_PRINT&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;      , &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_26"&gt;OLECMDEXECOPT&lt;/span&gt;.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_27"&gt;OLECMDEXECOPT&lt;/span&gt;_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_28"&gt;PROMPTUSER&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;      , ref n&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:85%;"&gt;      , ref n);&lt;/span&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;/span&gt;&lt;br /&gt;It worked! (&lt;a href="http://msdn2.microsoft.com/en-us/library/bb159690.aspx"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_29"&gt;MSDN&lt;/span&gt; says&lt;/a&gt; that the two pointers are optional so I just put null in there.)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-116070977329410159?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116070977329410159/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116070977329410159' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116070977329410159'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116070977329410159'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2008/04/printing-pdf-using-webbrowser-control.html' title='Printing PDF Using WebBrowser Control in .Net 2.0'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-7262879292586919340</id><published>2007-07-27T22:13:00.000+08:00</published><updated>2007-07-27T22:23:19.762+08:00</updated><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='wcf'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>WCF</title><content type='html'>&lt;span style="font-family:trebuchet ms;"&gt;This week I had a Windows Communications Foundation training from &lt;/span&gt;&lt;a href="http://www.develop.com/"&gt;&lt;span style="font-family:trebuchet ms;"&gt;Developmentor&lt;/span&gt;&lt;/a&gt;&lt;span style="font-family:trebuchet ms;"&gt;, sponsored by our company. I learned a lot about the new framework (dotnet 3.0) and communications. What interested me the most was the Day 4 topic which was Peer-to-peer applications. Although I might not be able to use it for regular business applications, I would be using it just for fun.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:trebuchet ms;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:trebuchet ms;"&gt;Here is our instructor's (Scott Reed) del.icio.us link:&lt;/span&gt;&lt;br /&gt;&lt;a href="http://del.icio.us/mscottreed"&gt;&lt;span style="font-family:trebuchet ms;"&gt;http://del.icio.us/mscottreed&lt;/span&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-7262879292586919340?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.develop.com/us/training/course.aspx?id=376' title='WCF'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/7262879292586919340/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=7262879292586919340' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/7262879292586919340'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/7262879292586919340'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2007/07/wcf.html' title='WCF'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-499181230095165673</id><published>2007-02-06T16:04:00.000+08:00</published><updated>2007-02-06T16:22:01.138+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='internet explorer'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Re: Do JavaScript after window.close()</title><content type='html'>There is a slight modification for &lt;a href="http://alexrazon.blogspot.com/2007/01/do-javascript-after-windowclose.html"&gt;my previous post&lt;/a&gt;. The conditions for the if statement there is inadequate. The bug occurs when refreshing the browser when the mouse is beyond the leftmost side of the window, a valid yet unanticipated negative value for the X. This is evident especially for dual monitors--like what I am using. Thus the new conditions are as follow:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;if&lt;/span&gt; (window.&lt;span style="color: rgb(51, 51, 255);"&gt;event&lt;/span&gt;.clientX &lt; &lt;span style="color: rgb(153, 0, 0);"&gt;0&lt;/span&gt;&lt;br /&gt;&amp;&amp;amp; window.&lt;span style="color: rgb(51, 51, 255);"&gt;event&lt;/span&gt;.clientY &lt; &lt;span style="color: rgb(153, 0, 0);"&gt;0&lt;/span&gt;&lt;br /&gt;&amp;&amp;amp; (window.&lt;span style="color: rgb(51, 51, 255);"&gt;event&lt;/span&gt;.clientX &lt; &lt;span style="color: rgb(153, 0, 0);"&gt;-1000&lt;/span&gt; || window.&lt;span style="color: rgb(51, 51, 255);"&gt;event&lt;/span&gt;.clientY &lt; &lt;span style="color: rgb(153, 0, 0);"&gt;-1000&lt;/span&gt;)) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt; &lt;span style="color: rgb(0, 153, 0);"&gt;//do closing routine...&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The 1000 value is a safe value for anticipating the event that we really expect--i.e. closing the window. Apparently, values lower than that seem to cause erroneous triggering.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-499181230095165673?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/499181230095165673/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=499181230095165673' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/499181230095165673'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/499181230095165673'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2007/02/re-do-javascript-after-windowclose.html' title='Re: Do JavaScript after window.close()'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-6712004604670239379</id><published>2007-02-06T15:45:00.000+08:00</published><updated>2007-02-06T16:03:52.983+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Re: JavaScript Hashtable Implementation</title><content type='html'>This is in response to my previous post re &lt;a href="http://alexrazon.blogspot.com/2006/11/javascript-hashtable-implementation.html"&gt;JavaScript Hashtable Implementation&lt;/a&gt;. I modified my code to be able to remove elements, as well as get an enumeration of the elements in cases wherein the keys are strings rather than integers.&lt;br /&gt;&lt;br /&gt;Here are the new members of the Hashtable object:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Methods:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;remove(string keyName)&lt;/span&gt;&lt;/span&gt; - Remove an element by key name&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;getAt(int index)&lt;/span&gt;&lt;/span&gt; - Get the value at the specified index&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;getEnum[int index]&lt;/span&gt;&lt;/span&gt; - Get the &lt;u&gt;key&lt;/u&gt; name at the specified index&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Properties:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;count&lt;/span&gt;&lt;/span&gt; - Get the number of elements of the Hashtable object&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;location&lt;/span&gt;&lt;/span&gt; - (&lt;span style="font-style: italic;"&gt;deprecated&lt;/span&gt;)&lt;br /&gt;&lt;br /&gt;So, here's the new code:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="color: rgb(0, 153, 0);font-family:courier new;" &gt;// create an instance of the hashtable object&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;function&lt;/span&gt; Hashtable(){&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.hash = &lt;span style="color: rgb(51, 51, 255);"&gt;new &lt;/span&gt;Array();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys = &lt;span style="color: rgb(51, 51, 255);"&gt;new &lt;/span&gt;Array();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.getEnum = &lt;span style="color: rgb(51, 51, 255);"&gt;new &lt;/span&gt;Array();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.count = &lt;span style="color: rgb(153, 0, 0);"&gt;0&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.hash = &lt;span style="color: rgb(51, 51, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.keys = &lt;span style="color: rgb(51, 51, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.count = &lt;span style="color: rgb(51, 51, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.getEnum = &lt;span style="color: rgb(51, 51, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 153, 0);font-family:courier new;" &gt;// get the value at the specified index&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.getAt = &lt;span style="color: rgb(51, 51, 255);"&gt;function &lt;/span&gt;(index) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;return this&lt;/span&gt;.hash[&lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.getEnum[index]];&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 153, 0);font-family:courier new;" &gt;// get the corresponding value&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.get = &lt;span style="color: rgb(51, 51, 255);"&gt;function &lt;/span&gt;(key) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;return this&lt;/span&gt;.hash[key];&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.remove = &lt;span style="color: rgb(51, 51, 255);"&gt;function &lt;/span&gt;(key) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;    for&lt;/span&gt; (&lt;span style="color: rgb(51, 51, 255);"&gt;var&lt;/span&gt; i = &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys.length - &lt;span style="color: rgb(153, 0, 0);"&gt;1&lt;/span&gt;; i &gt;= &lt;span style="color: rgb(153, 0, 0);"&gt;0&lt;/span&gt;; i--) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;        if&lt;/span&gt; (&lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys[i] == key) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;            &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys.splice(i, &lt;span style="color: rgb(153, 0, 0);"&gt;1&lt;/span&gt;);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;            &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.getEnum.splice(i, &lt;span style="color: rgb(153, 0, 0);"&gt;1&lt;/span&gt;);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;            &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.hash[key] = &lt;span style="color: rgb(51, 51, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;            &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.count = &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys.length;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 153, 0);font-family:courier new;" &gt;// create an entry in the hashtable&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Hashtable.&lt;span style="color: rgb(51, 51, 255);"&gt;prototype&lt;/span&gt;.put = &lt;span style="color: rgb(51, 51, 255);"&gt;function&lt;/span&gt; (key, value) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;    if&lt;/span&gt; (value == &lt;span style="color: rgb(51, 51, 255);"&gt;null&lt;/span&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;        return null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 153, 0);font-family:courier new;" &gt;    // create a new entry&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;    if&lt;/span&gt; (&lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.hash[key] == &lt;span style="color: rgb(51, 51, 255);"&gt;null&lt;/span&gt;) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys[&lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys.length] = key;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.count = &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.keys.length;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.getEnum[&lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.count - &lt;span style="color: rgb(153, 0, 0);"&gt;1&lt;/span&gt;]= key;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 153, 0);font-family:courier new;" &gt;    // set the value&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;.hash[key] = value;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&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/24582276-6712004604670239379?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/6712004604670239379/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=6712004604670239379' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6712004604670239379'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6712004604670239379'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2007/02/re-javascript-hashtable-implementation.html' title='Re: JavaScript Hashtable Implementation'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-4048745298459350041</id><published>2007-01-12T10:30:00.000+08:00</published><updated>2007-01-12T10:35:45.841+08:00</updated><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='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='iis'/><title type='text'>IIS 5.1: 403.9 - Access Forbidden: Too many users are connected</title><content type='html'>I found &lt;a href="HTTP%20403.9%20-%20Access%20Forbidden:%20Too%20many%20users%20are%20connected"&gt;this blog&lt;/a&gt; that addresses my concern in IIS 5.1 for Windows XP. I recently discovered that it is crippled in such a way that it only allows 10 concurrent connections. Moreover, it is hardcoded to be configured to at most 40.  If the maximum concurrent connections have been reached, your website's users will receive the following error:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;&lt;blockquote&gt;HTTP 403.9 - Access Forbidden: Too many users are connected&lt;/blockquote&gt;&lt;/span&gt;The workaround involves modifying the maximum allowable connections to 40. Still, you're stuck at 40.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-4048745298459350041?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.codinghorror.com/blog/archives/000329.html' title='IIS 5.1: 403.9 - Access Forbidden: Too many users are connected'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/4048745298459350041/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=4048745298459350041' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/4048745298459350041'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/4048745298459350041'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2007/01/iis-51-4039-access-forbidden-too-many.html' title='IIS 5.1: 403.9 - Access Forbidden: Too many users are connected'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-6458984239003377162</id><published>2007-01-09T18:50:00.000+08:00</published><updated>2007-01-09T18:59:43.927+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='internet explorer'/><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Do JavaScript after window.close()</title><content type='html'>I needed to do some routines when a user has closed the window.  I do not want those routines to trigger when refreshing the page or unloading the document; I just need them to happen when the browser window is closed.&lt;br /&gt;&lt;br /&gt;This is the usual proposed solution: assign a function on the &lt;span style="font-weight: bold;font-family:courier new;" &gt;onbeforeunload &lt;/span&gt;event of the body or window. The problem with this is it also triggers when refreshing or moving away from the page (i.e. back or forward). I stumbled upon a solution that proposes tapping the &lt;span style="font-weight: bold;font-family:courier new;" &gt;onunload &lt;/span&gt;event instead. Thus, I have a function like this:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;&lt;/span&gt;&lt;/span&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;function &lt;/span&gt;body_unload() {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;if &lt;/span&gt;(window.&lt;span style="color: rgb(51, 51, 255);"&gt;event&lt;/span&gt;.clientX &lt; &lt;span style="color: rgb(255, 0, 0);"&gt;0&lt;/span&gt;) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        alert(&lt;span style="color: rgb(153, 0, 0);"&gt;"The user is closing the window."&lt;/span&gt;);                            &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    } else {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        alert(&lt;span style="color: rgb(153, 0, 0);"&gt;"The user is refreshing or navigating away."&lt;/span&gt;);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }        &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;/blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;I then assign this to the &lt;span style="font-weight: bold;font-family:courier new;" &gt;onunload &lt;/span&gt;event of the body. From there I could perform my JavaScript and/or AJAX routines.&lt;br /&gt;&lt;br /&gt;Although this works for my purposes, the main downside of this is that I cannot issue a confirm dialog. The page has been unloaded at this point.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-6458984239003377162?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/6458984239003377162/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=6458984239003377162' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6458984239003377162'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6458984239003377162'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2007/01/do-javascript-after-windowclose.html' title='Do JavaScript after window.close()'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-2379979523102043143</id><published>2007-01-09T10:34:00.000+08:00</published><updated>2007-01-09T10:49:48.109+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='internet explorer'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Javascript: How to close the browser window without the IE warning</title><content type='html'>In Internet Explorer, when you use window.close() in JavaScript to close the current browser window, you will be asked something like "A script is attempting to close this window. Do you want to continue?" As a programmer, this can be annoying if you are &lt;span style="font-style: italic;"&gt;un&lt;/span&gt;-maliciously closing the window. A workaround to this would be setting the &lt;span style="font-weight: bold;font-family:courier new;" &gt;window.opener&lt;/span&gt; property to something else.&lt;br /&gt;&lt;br /&gt;Example:&lt;br /&gt;&lt;br /&gt;In your JavaScript, have something like:&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;function &lt;/span&gt;logoff() {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;if &lt;/span&gt;(confirm(&lt;span style="color: rgb(153, 0, 0);"&gt;"Do you want to log off?"&lt;/span&gt;)) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;window&lt;/span&gt;.opener = "x";&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;window&lt;/span&gt;.close();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Then in your HTML, have a button or link that calls this JavaScript function onclick.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-2379979523102043143?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/2379979523102043143/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=2379979523102043143' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/2379979523102043143'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/2379979523102043143'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2007/01/javascript-how-to-close-browser-window.html' title='Javascript: How to close the browser window without the IE warning'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-6944381549179868116</id><published>2006-12-14T20:01:00.000+08:00</published><updated>2006-12-14T20:19:07.633+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><title type='text'>Access Control Lists</title><content type='html'>Ever had Windows XP crash? And worse comes to worse you had to reformat your PC and you need to back up your data? The BIG problem is: you can't access your folders! Well, here's a workaround I've gathered around the net (that is yet to be personally tested). It is however assumed that you haven't encrypted (i.e. files with green filenames) your  files. That is "irreversible" and thus cannot be recovered.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;1. Use your drive as a slave drive in another computer. The master should have a Windows XP installed and the user logged on must have administrator rights. Let's say your data drive is D: while your system drive is C:.&lt;br /&gt;2. Open your trusty command prompt and type the following:&lt;br /&gt;&lt;div style="text-align: center; font-family: courier new;"&gt;cacls [FOLDER or FILENAME] /E /P [USERNAME]:F&lt;/div&gt;where: FOLDER or FILENAME = the name of folder or filename to gain access to&lt;br /&gt;USERNAME = the currently logged-in user's Windows XP account name&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-weight: bold;"&gt;CALCS &lt;/span&gt;is the command to display or modify &lt;a href="http://en.wikipedia.org/wiki/Access_control_list"&gt;access control lists (ACLs)&lt;/a&gt; of files.&lt;br /&gt;/E            Edit ACL instead of replacing it.&lt;br /&gt;/P user:perm  Replace specified user's access rights.&lt;br /&gt;            Perm can be: N  None&lt;br /&gt;                         R  Read&lt;br /&gt;                         W  Write&lt;br /&gt;                         C  Change (write)&lt;br /&gt;                         F  Full control&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;3. To restore the ACL for that folder/file:&lt;br /&gt;&lt;div style="text-align: center; font-family: courier new;"&gt;cacls [FOLDER or FILENAME] /E /R [USERNAME]&lt;/div&gt;&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-6944381549179868116?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/6944381549179868116/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=6944381549179868116' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6944381549179868116'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6944381549179868116'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/12/access-control-lists.html' title='Access Control Lists'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-3544337787998981438</id><published>2006-11-27T22:43:00.001+08:00</published><updated>2006-11-27T23:13:57.666+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>ArrayList sorting via IComparable</title><content type='html'>The problem: I have a two-dimensional object array. Each first level element of the array contains five object elements--except for the last one, which only has three. However, I have a procedure that needs to concatenate another array at the end of the original one. Since I need to put the unique three-element object array at the end of the list, I had to find a solution to sort it via the elements' length.&lt;br /&gt;&lt;br /&gt;The immediate solution was to use ArrayList.Sort(IComparer). Okay I created a class that looked similar to this:&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;class &lt;/span&gt;&lt;span style="color: rgb(51, 153, 153);"&gt;MyComparer &lt;/span&gt;: &lt;span style="color: rgb(51, 153, 153);"&gt;IComparable&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;private object &lt;/span&gt;_data;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;public object&lt;/span&gt; Data&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;       &lt;span style="color: rgb(51, 51, 255);"&gt; get &lt;/span&gt;{ &lt;span style="color: rgb(51, 51, 255);"&gt;return &lt;/span&gt;_data; }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;public &lt;/span&gt;MyComparer(&lt;span style="color: rgb(51, 51, 255);"&gt;object &lt;/span&gt;data)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        _data = data;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;int &lt;/span&gt;&lt;span style="color: rgb(51, 153, 153);"&gt;IComparable&lt;/span&gt;.CompareTo(&lt;span style="color: rgb(51, 51, 255);"&gt;object &lt;/span&gt;obj)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 153, 153);"&gt;MyComparer &lt;/span&gt;mc = (&lt;span style="color: rgb(51, 153, 153);"&gt;MyComparer&lt;/span&gt;)obj;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;object&lt;/span&gt;[] myData = &lt;span style="color: rgb(51, 51, 255);"&gt;this&lt;/span&gt;._data &lt;span style="color: rgb(51, 51, 255);"&gt;as object&lt;/span&gt;[];&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;object&lt;/span&gt;[] thatData = mc.Data &lt;span style="color: rgb(51, 51, 255);"&gt;as object&lt;/span&gt;[];&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        &lt;span style="color: rgb(51, 51, 255);"&gt;return &lt;/span&gt;(myData.Length &lt; thatData.Length) ? 0 : -1;   }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;To use it in one of my methods:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;private static object&lt;/span&gt;[] _sortChartData(&lt;span style="color: rgb(51, 51, 255);"&gt;object&lt;/span&gt;[] oData)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 153, 153);"&gt;ArrayList &lt;/span&gt;arrData = &lt;span style="color: rgb(51, 51, 255);"&gt;new &lt;/span&gt;&lt;span style="color: rgb(51, 153, 153);"&gt;ArrayList&lt;/span&gt;();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;for &lt;/span&gt;(&lt;span style="color: rgb(51, 51, 255);"&gt;int &lt;/span&gt;i = 0; i &lt;code&gt;&lt;&lt;/code&gt; oData.Length; i++)   {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        arrData.Add(&lt;span style="color: rgb(51, 51, 255);"&gt;new &lt;/span&gt;&lt;span style="color: rgb(51, 153, 153);"&gt;MyComparer&lt;/span&gt;(oData[i]));&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    arrData.Sort();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;for &lt;/span&gt;(&lt;span style="color: rgb(51, 51, 255);"&gt;int &lt;/span&gt;j = 0; j &lt;code&gt;&lt;&lt;/code&gt; arrData.Count; j++)    {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;        arrData[j] = (arrData[j] &lt;span style="color: rgb(51, 51, 255);"&gt;as &lt;/span&gt;&lt;span style="color: rgb(51, 153, 153);"&gt;MyComparer&lt;/span&gt;).Data;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;return &lt;/span&gt;arrData.ToArray();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;With this I can sort the contents of the original object[] to the one desired.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-3544337787998981438?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/3544337787998981438/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=3544337787998981438' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/3544337787998981438'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/3544337787998981438'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/11/arraylist-sorting-via-icomparable_27.html' title='ArrayList sorting via IComparable'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-6298098971161409044</id><published>2006-11-20T08:24:00.000+08:00</published><updated>2006-11-20T09:20:17.165+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Predicates in dotNet</title><content type='html'>I've come across Predicates in dotNet 2.0. I felt so disgusted with too many foreach loops when looping through list collections. So, here was my problem: I have three string Lists&lt;string&gt;, say, A, B and C. List&lt;string&gt; string A is the reference list; while B and C contain elements found in A. By brute force method (and practically the only way we can do it in dotNet 1.x), we do something like:&lt;br /&gt;&lt;/string&gt;&lt;/string&gt;&lt;blockquote  style="font-family:courier new;"&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;foreach&lt;/span&gt; (&lt;span style="color: rgb(51, 51, 255);"&gt;string &lt;/span&gt;strA in A)&lt;br /&gt;{&lt;br /&gt; &lt;span style="color: rgb(51, 51, 255);"&gt;foreach &lt;/span&gt;(&lt;span style="color: rgb(51, 51, 255);"&gt;string &lt;/span&gt;strB &lt;span style="color: rgb(51, 51, 255);"&gt;in &lt;/span&gt;B)&lt;br /&gt; {&lt;br /&gt;     &lt;span style="color: rgb(51, 51, 255);"&gt;if &lt;/span&gt;(strB.Contains(strB)) { &lt;span style="color: rgb(0, 153, 0);"&gt;/* do something... */&lt;/span&gt; }&lt;br /&gt; }&lt;br /&gt; &lt;span style="color: rgb(51, 51, 255);"&gt;foreach &lt;/span&gt;(&lt;span style="color: rgb(51, 51, 255);"&gt;string &lt;/span&gt;strC &lt;span style="color: rgb(51, 51, 255);"&gt;in &lt;/span&gt;C)&lt;br /&gt; {&lt;br /&gt;     &lt;span style="color: rgb(51, 51, 255);"&gt;if &lt;/span&gt;(strC.StartsWith(strC)) { &lt;span style="color: rgb(0, 153, 0);"&gt;/* do something... */&lt;/span&gt; }&lt;br /&gt; }&lt;br /&gt;}&lt;br /&gt;&lt;/span&gt;&lt;/blockquote&gt;&lt;br /&gt;In dotNet 2.0, Predicates are provided for the generic features such as the System.Array and System.Collections.Generic.List classes. These classes provide methods like Find, FindAll, FindLast, etc. that use predicates to help developers search for certain elements in collections via delegates rather than looping at each element. Developers get the ability to "walk" an entire data structure, determining whether each item meets a set of criteria, without having to write the boilerplate code to loop through each row manually. In addition, it is more efficient to go.&lt;br /&gt;&lt;br /&gt;Okay, back to our example. By employing predicates, I created a new class called StringFilter:&lt;br /&gt;&lt;blockquote  style="font-family:courier new;"&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;public class&lt;/span&gt; &lt;span style="color: rgb(51, 153, 153);"&gt;StringFilter&lt;/span&gt;&lt;br /&gt;{&lt;br /&gt; &lt;span style="color: rgb(51, 51, 255);"&gt;private string&lt;/span&gt; _strReference;&lt;br /&gt; &lt;span style="color: rgb(51, 51, 255);"&gt;public bool&lt;/span&gt; ContainsString(string s)&lt;br /&gt; {&lt;br /&gt;     &lt;span style="color: rgb(51, 51, 255);"&gt;return&lt;/span&gt; s.Contains(_strReference);&lt;br /&gt; }&lt;br /&gt; &lt;span style="color: rgb(51, 51, 255);"&gt;public bool&lt;/span&gt; StartsWithString(string s)&lt;br /&gt; {&lt;br /&gt;     &lt;span style="color: rgb(51, 51, 255);"&gt;return&lt;/span&gt; s.StartsWith(_strReference, &lt;span style="color: rgb(51, 153, 153);"&gt;StringComparison&lt;/span&gt;.InvariantCultureIgnoreCase);&lt;br /&gt; }&lt;br /&gt; &lt;span style="color: rgb(51, 51, 255);"&gt;public &lt;/span&gt;StringFilter(string strReference)&lt;br /&gt; {&lt;br /&gt;     _strReference = strReference;&lt;br /&gt; }&lt;br /&gt;}&lt;/span&gt;&lt;/blockquote&gt;&lt;br /&gt;Now, rewriting our example using this new class as predicate:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;&lt;/span&gt;&lt;/span&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="color: rgb(51, 51, 255);"&gt;foreach &lt;/span&gt;(&lt;span style="color: rgb(51, 51, 255);"&gt;string &lt;/span&gt;strA &lt;span style="color: rgb(51, 51, 255);"&gt;in&lt;/span&gt; A)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 153, 153);"&gt;StringFilter&lt;/span&gt; sf = &lt;span style="color: rgb(51, 51, 255);"&gt;new&lt;/span&gt; &lt;span style="color: rgb(51, 153, 153);"&gt;StringFilter&lt;/span&gt;(strA);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;if&lt;/span&gt; (B.Exists(sf.ContainsString)) { &lt;span style="color: rgb(0, 153, 0);"&gt;/* do something... */&lt;/span&gt; }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    &lt;span style="color: rgb(51, 51, 255);"&gt;if&lt;/span&gt; (C.Exists(sf.StartsWithString)) { &lt;span style="color: rgb(0, 153, 0);"&gt;/* do something... */&lt;/span&gt; }&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;}&lt;/span&gt;&lt;/blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;/span&gt;The new class provides flexibility in searching elements of the collection.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-6298098971161409044?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://msdn2.microsoft.com/en-us/library/bfcke1bz.aspx' title='Predicates in dotNet'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/6298098971161409044/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=6298098971161409044' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6298098971161409044'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/6298098971161409044'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/11/predicates-in-dotnet.html' title='Predicates in dotNet'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-7069599304833100290</id><published>2006-11-16T07:34:00.000+08:00</published><updated>2006-11-16T07:40:38.770+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='office 2007'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><title type='text'>Office 2007</title><content type='html'>The recent Office 2007 RTM presents a bug when opening buildingblocks.dotx. The solution for this is to delete the file and let Office recreate it. It can be located in:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;%drive%:\Documents and Settings\%username%\Application Data\Microsoft\Document Building Blocks\1033&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-7069599304833100290?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/7069599304833100290/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=7069599304833100290' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/7069599304833100290'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/7069599304833100290'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/11/office-2007.html' title='Office 2007'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116313754521183601</id><published>2006-11-10T13:39:00.000+08:00</published><updated>2006-11-16T07:39:53.947+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='xpath'/><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Selecting Xml Nodes in MSXML 3 via XPath</title><content type='html'>Apparently, you need to set the SelectionLanguage property of a JavaScript XML Document object to XPath so you can select nodes via XPath.&lt;br /&gt;&lt;blockquote&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;&lt;span style="color: rgb(51, 51, 255);font-family:courier new;" &gt;var&lt;/span&gt;&lt;span style="font-family:courier new;"&gt; xmldoc = &lt;/span&gt;&lt;span style="color: rgb(51, 51, 255);font-family:courier new;" &gt;new &lt;/span&gt;&lt;span style="font-family:courier new;"&gt;ActiveXObject("Microsoft.XMLDOM");&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 153, 0);font-family:courier new;" &gt;// or var xmldoc = new ActiveXObject('Msxml2.DOMDocument.3.0');&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;xmldoc.async = "false";&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;xmldoc.loadXML(xmlData);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;xmldoc.setProperty(&lt;/span&gt;&lt;span style="color: rgb(153, 0, 0);font-family:courier new;" &gt;"SelectionLanguage"&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;, &lt;/span&gt;&lt;span style="color: rgb(153, 0, 0);font-family:courier new;" &gt;"XPath"&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;);&lt;/span&gt;&lt;/span&gt;&lt;/blockquote&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;After which you can use XPath to select nodes. This is inevitable for MSXML 3.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-116313754521183601?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116313754521183601/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116313754521183601' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116313754521183601'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116313754521183601'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/11/selecting-xml-nodes-in-msxml-3-via.html' title='Selecting Xml Nodes in MSXML 3 via XPath'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116304847023819340</id><published>2006-11-09T12:57:00.000+08:00</published><updated>2006-11-16T07:41:07.942+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Re: Introducing .NET Framework 3.0</title><content type='html'>It is officially released.&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;The Microsoft .NET Framework 3.0 is the new managed code programming model for Windows®. It combines the power of the .NET Framework version 2.0 with new technologies for building applications that have visually compelling user experiences, seamless communication across technology boundaries, and the ability to support a wide range of business processes. These new technologies are Windows Presentation Foundation, Windows Communication Foundation, Windows Workflow Foundation, and Windows CardSpace. The .NET Framework 3.0 is included as part of the Windows Vista™ operating system; you can install it or uninstall it using Windows Features Control Panel. This redistributable package is for Windows XP and Windows Server 2003. &lt;/blockquote&gt;&lt;u style="font-weight: bold;"&gt;Downloads:&lt;/u&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=10CC340B-F857-4A14-83F5-25634C3BF043&amp;displaylang=en"&gt;.NET Framework 3.0 Runtime Components&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=C2B1E300-F358-4523-B479-F53D234CDCCF&amp;amp;displaylang=en"&gt;Windows SDK for Vista and the .NET Framework 3.0&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=5D61409E-1FA3-48CF-8023-E8F38E709BA6&amp;displaylang=en"&gt;Visual Studio 2005 Extensions for .NET Framework 3.0 (Windows Workflow Foundation)&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=F54F5537-CC86-4BF5-AE44-F5A1E805680D&amp;amp;displaylang=en"&gt;Visual Studio 2005 Extensions for .NET Framework 3.0 (WCF &amp;amp; WPF), November 2006 CTP&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-116304847023819340?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116304847023819340/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116304847023819340' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116304847023819340'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116304847023819340'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/11/re-introducing-net-framework-30.html' title='Re: Introducing .NET Framework 3.0'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116280187158853798</id><published>2006-11-06T16:29:00.000+08:00</published><updated>2006-11-16T07:42:16.444+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='vb6'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Get the volume serial number of a drive</title><content type='html'>This code returns the volume serial for a hard drive (VB6).&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Code&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;blockquote&gt;&lt;span style="font-family:courier new;"&gt;Public Declare Function GetVolumeSerialNumber Lib "kernel32" Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, ByVal lpVolumeNameBuffer As Long, ByVal nVolumeNameSize As Long, lpVolumeSerialNumber As Long, ByVal lpMaximumComponentLength As Long, ByVal lpFileSystemFlags As Long, ByVal lpFileSystemNameBuffer As Long, ByVal nFileSystemNameSize As Long) As Long&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Public Function VolumeSerial(DriveLetter) As Long&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    Dim Serial As Long&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    Call GetVolumeSerialNumber(UCase(DriveLetter) &amp; ":\", 0&amp;amp;, 0&amp;, Serial, 0&amp;amp;amp;amp;, 0&amp;, 0&amp;amp;, 0&amp;)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;    VolumeSerial = Serial&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;End Function&lt;/span&gt;&lt;/blockquote&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Example Usage&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;blockquote&gt;MsgBox VolumeSerial("C") &lt;/blockquote&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/24582276-116280187158853798?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116280187158853798/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116280187158853798' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116280187158853798'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116280187158853798'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/11/get-volume-serial-number-of-drive.html' title='Get the volume serial number of a drive'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116278481359203268</id><published>2006-11-06T11:42:00.000+08:00</published><updated>2006-11-14T10:21:00.098+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>JavaScript Hashtable Implementation</title><content type='html'>I needed a hashtable implementation in JavaScript and here's what I’ve come up. It is used like this:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family: courier new;"&gt;&lt;span style="color: rgb(51, 102, 255);"&gt;&lt;/span&gt;&lt;/span&gt;&lt;blockquote&gt;&lt;span style="font-family: courier new;"&gt;&lt;span style="color: rgb(51, 102, 255);"&gt;var&lt;/span&gt; ht = &lt;span style="color: rgb(51, 102, 255);"&gt;new &lt;/span&gt;Hashtable();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;ht.put(&lt;span style="color: rgb(153, 0, 0);"&gt;“key”&lt;/span&gt;, &lt;span style="color: rgb(153, 0, 0);"&gt;“value”&lt;/span&gt;);&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;&lt;span style="color: rgb(51, 102, 255);"&gt;var&lt;/span&gt; val = ht.get(&lt;span style="color: rgb(153, 0, 0);"&gt;“key”&lt;/span&gt;); &lt;span style="color: rgb(0, 153, 0);"&gt;// returns null if not found&lt;/span&gt;&lt;/span&gt;&lt;/blockquote&gt;&lt;span style="font-family: courier new;"&gt;&lt;span style="color: rgb(0, 153, 0);"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The implementation is like this:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family: courier new;"&gt;&lt;span style="color: rgb(51, 102, 255);"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;blockquote&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family: courier new;"&gt;&lt;span style="color: rgb(51, 102, 255);"&gt;function&lt;/span&gt; Hashtable(){&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;this&lt;/span&gt;.hash = &lt;span style="color: rgb(51, 102, 255);"&gt;new &lt;/span&gt;Array();&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;this&lt;/span&gt;.keys = &lt;span style="color: rgb(51, 102, 255);"&gt;new &lt;/span&gt;Array();&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;this&lt;/span&gt;.location = 0;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Hashtable.prototype.hash = &lt;span style="color: rgb(51, 102, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Hashtable.prototype.keys = &lt;span style="color: rgb(51, 102, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Hashtable.prototype.location = &lt;span style="color: rgb(51, 102, 255);"&gt;null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Hashtable.prototype.get = &lt;span style="color: rgb(51, 102, 255);"&gt;function &lt;/span&gt;(key) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;return this&lt;/span&gt;.hash[key];&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Hashtable.prototype.put = &lt;span style="color: rgb(51, 102, 255);"&gt;function &lt;/span&gt;(key, value) {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;if &lt;/span&gt;(value == &lt;span style="color: rgb(51, 102, 255);"&gt;null&lt;/span&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;        &lt;span style="color: rgb(51, 102, 255);"&gt;return null&lt;/span&gt;;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;if &lt;/span&gt;(&lt;span style="color: rgb(51, 102, 255);"&gt;this&lt;/span&gt;.hash[key] == null)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;        &lt;span style="color: rgb(51, 102, 255);"&gt;this&lt;/span&gt;.keys[&lt;span style="color: rgb(51, 102, 255);"&gt;this&lt;/span&gt;.keys.length] = key;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    &lt;span style="color: rgb(51, 102, 255);"&gt;this&lt;/span&gt;.hash[key] = value;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;} &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-116278481359203268?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116278481359203268/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116278481359203268' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116278481359203268'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116278481359203268'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/11/javascript-hashtable-implementation.html' title='JavaScript Hashtable Implementation'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116217989112320240</id><published>2006-10-30T11:42:00.000+08:00</published><updated>2006-11-14T10:21:00.036+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='open source'/><category scheme='http://www.blogger.com/atom/ns#' term='IT news'/><title type='text'>Get Songbird!</title><content type='html'>Songbird™ is a desktop Web player, a digital jukebox and Web browser mash-up. Like Winamp, it supports extensions and skins feathers. Like Firefox®, it is built from Mozilla®, cross-platform and open source.&lt;br /&gt;&lt;a href="http://songbirdnest.com"&gt;&lt;img src="http://songbirdnest.com/files/images/button_feedme.png" border="0" alt="Get Songbird" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-116217989112320240?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116217989112320240/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116217989112320240' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116217989112320240'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116217989112320240'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/10/get-songbird.html' title='Get Songbird!'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116183846478223685</id><published>2006-10-26T12:52:00.000+08:00</published><updated>2006-11-14T10:20:59.974+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>GotAPI.Com</title><content type='html'>I stumbled upon this &lt;a href="http://www.gotapi.com/"&gt;site&lt;/a&gt; that provides quick reference to Web development.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-116183846478223685?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.gotapi.com/' title='GotAPI.Com'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116183846478223685/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116183846478223685' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116183846478223685'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116183846478223685'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/10/gotapicom.html' title='GotAPI.Com'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-116070255563660150</id><published>2006-10-13T09:08:00.000+08:00</published><updated>2006-11-14T10:20:59.912+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='vb6'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Printer and the CommonDialog</title><content type='html'>In VB6, in order for you to make the Printer object in VB6 recognize the return of the  CommonDialog.ShowPrinter method, you have to set something like:&lt;br /&gt;&lt;br /&gt;Printer.TrackDefault = True&lt;br /&gt;' then show the printer dialog&lt;br /&gt;commonDialog1.ShowPrinter&lt;br /&gt;&lt;br /&gt;The only problem here is that the commonDialog.DefaultPrinter is set to True by default. Thus, it practically sets the default printer to the selected. Any subsequent calls to the Printer object follow the printer selected in the Printer Dialog Box. Essentially you are setting a default printer via the dialog.&lt;br /&gt;&lt;br /&gt;I have yet to find a way to retrieve the hDC (printer device handle) from the CommonDialog Print dialog such that it can be passed to the Printer object--if it indeed is possible. Because right now, I don't think this is the most efficient way to do it.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-116070255563660150?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/116070255563660150/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=116070255563660150' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116070255563660150'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/116070255563660150'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/10/printer-and-commondialog.html' title='Printer and the CommonDialog'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115707428691838466</id><published>2006-09-01T09:06:00.000+08:00</published><updated>2006-11-14T10:20:59.828+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Compiler Error CS0030 with Ajax</title><content type='html'>When using Ajax Pro, you have to add the runat="server" tag on the form to be used. In other words, you have to have at least one server-side form in the class whose type is to be registered as an Ajax class. Otherwise, you'll end up with a Compiler Error CS0030 Error Message Cannot convert type 'type' to 'type'. It took me almost an hour troubleshooting this.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115707428691838466?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115707428691838466/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115707428691838466' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115707428691838466'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115707428691838466'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/09/compiler-error-cs0030-with-ajax.html' title='Compiler Error CS0030 with Ajax'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115691305377102279</id><published>2006-08-30T11:34:00.000+08:00</published><updated>2006-11-14T10:20:59.763+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Re:  Ajax Lecture at the Mapua</title><content type='html'>A student/colleague during the recent Ajax Lecture at Mapua brought up &lt;a href="http://www.anthemdotnet.com/"&gt;Anthem.NET&lt;/a&gt;. It is an Ajax "framework" for .Net web applications. Since it's the first time I heard about it, I took some time learning it and how it works.&lt;br /&gt;&lt;br /&gt;From what I've found so far, it makes it easier for developers to build Ajax-based dotNet web application. For instance, with the widespread AjaxPro library, you have to manually implement Ajax on each method to be invoked. Ajax classes can be attributed as such, yes, but if you want to make custom controls with Ajax implementation, you have to make it for yourself. In a nutshell, since AjaxPro is an Ajax "wrapper" that you can just reference to, you still have to get your hands dirty in creating the actual rich controls Ajax is famous for.&lt;br /&gt;&lt;br /&gt;Anthem.NET has made it easier by packaging custom controls wherein developers can use the familiar "runat=server" tag and attributes such as PreCallBackFunction, PostCallBackFunction and CallBackCancelledFunction (among many others). These attributes are valid server-side control attributes that can call client-side JavaScript functions. This is interesting because, you have more control on your Ajax invocations.&lt;br /&gt;&lt;br /&gt;I believe the backbone of Anthem.NET is very much like AjaxPro. Only Anthem.NET pushed it further with pre-built classes and server-side controls. It's actually more like Atlas.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115691305377102279?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115691305377102279/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115691305377102279' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115691305377102279'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115691305377102279'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/08/re-ajax-lecture-at-mapua.html' title='Re:  Ajax Lecture at the Mapua'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115641072438110749</id><published>2006-08-24T17:11:00.000+08:00</published><updated>2006-11-14T10:20:59.682+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Re: Simplest Solution that Could Possibly Work</title><content type='html'>&lt;blockquote&gt;... there is always a well-known solution to every human problem -- neat, plausible, and wrong. -- H. L. Mencken (1880-1956), "Prejudices"&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;This quote made me rethink my primary notions on my previous blog: Yes perhaps, the simplest solution is not that simple at all! It could be complex enough to be wrong.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Optimization&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;In general, there are two kinds of code optimization: one for speed and another one for space. By speed I mean the code executes in the least amount of time. By space I refer to code that executes in the least number of lines. It is oftentimes difficult to balance the two. But when you do, you get code that is atomic and easy to maintain.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115641072438110749?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115641072438110749/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115641072438110749' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115641072438110749'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115641072438110749'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/08/re-simplest-solution-that-could_24.html' title='Re: Simplest Solution that Could Possibly Work'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115600400149553654</id><published>2006-08-20T00:05:00.000+08:00</published><updated>2006-11-14T10:20:59.563+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Ajax Lecture at the Mapua</title><content type='html'>Yesterday I presented &lt;a href="http://www.answers.com/main/ntquery?s=ajax&amp;gwp=13"&gt;Asynchronous JavaScript and XML&lt;/a&gt; (Ajax) to a bunch of MSCS graduate students at the Mapua Institute of Technology. I needed to adjust my lecture to a level where most students (even those without or with minimal webapps experience) will be able to relate to.&lt;br /&gt;&lt;br /&gt;It was a great opportunity and privilege for me to be able to present my understanding of Ajax. I was also a learning experience for me.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;My Powerpoint presentation (with notes) can be downloaded &lt;/span&gt;&lt;a style="font-style: italic;" href="http://aluxious.googlepages.com/Ajax20060819.ppt"&gt;here&lt;/a&gt;&lt;span style="font-style: italic;"&gt;. The sample codes I used can also be downloaded and reviewed using this &lt;/span&gt;&lt;a style="font-style: italic;" href="http://aluxious.googlepages.com/AjaxWebSites.zip"&gt;link&lt;/a&gt;&lt;span style="font-style: italic;"&gt;.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115600400149553654?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115600400149553654/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115600400149553654' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115600400149553654'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115600400149553654'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/08/ajax-lecture-at-mapua.html' title='Ajax Lecture at the Mapua'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115500397116338681</id><published>2006-08-08T10:22:00.000+08:00</published><updated>2006-11-14T10:20:59.504+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='IT news'/><title type='text'>Borland Brings Back Its Turbo Tools</title><content type='html'>I remember doing my first few C/C++ programs in college using the Turbo IDE , which was still run in DOS. Now Borland is reviving it and packaging it with much more. Check out this &lt;a href="http://www.eweek.com/article2/0,1759,2000205,00.asp?kc=EWRSS03119TX1K0000594"&gt;link&lt;/a&gt; for details.&lt;br /&gt;&lt;blockquote&gt;On Aug. 8, the company's Developer Tools Group, which is up for sale, is scheduled to announce single-language versions of the components of Borland Developer Studio, the company's IDE (integrated development environment) for Microsoft Windows and .Net applications.&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115500397116338681?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.eweek.com/article2/0,1759,2000205,00.asp?kc=EWRSS03119TX1K0000594' title='Borland Brings Back Its Turbo Tools'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115500397116338681/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115500397116338681' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115500397116338681'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115500397116338681'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/08/borland-brings-back-its-turbo-tools.html' title='Borland Brings Back Its Turbo Tools'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115355477658895839</id><published>2006-07-22T15:15:00.000+08:00</published><updated>2006-11-14T10:20:59.442+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='open source'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='iis'/><title type='text'>Open Source Adventures</title><content type='html'>These past few days I have been exploring the OpenSource world and have been discovering great things from it. Most of my career so far have focused on Microsoft technologies, making me naive on the alternatives.&lt;br /&gt;&lt;br /&gt;First experiment: install PHP, MySql and Apache Server. I've read from forums that the best way to go was to install them individually. Okay I skipped that part--since there are programs like &lt;a href="http://www.apachefriends.org/en/xampp.html"&gt;XAMP&lt;/a&gt; and WAMP that does it automatically for me. Yes they are good programs and I've tried them but in the end I feel dumb and lost as to where to start. I guess the people from the forums are right. So I decided to install them piece by piece.&lt;br /&gt;&lt;br /&gt;Particularly I was successful in setting up PHP on IIS 5. As Microsoft cheapskate as I am, I downloaded the MSI installer for PHP5. I had no problems configuring it to work on IIS since the installer automatically did it for me. (Don't blame me; I needed a jump start on the thing!)&lt;br /&gt;&lt;br /&gt;Until I had a problem: I can't seem to employ &lt;a href="http://www.modernmethod.com/sajax/"&gt;Sajax&lt;/a&gt; on my PHP application. Loading images were quite a problem. (Footnote: I have been using Ajax.net for ASP.Net web applications.) First error I encountered was: "&lt;blockquote style="font-family: courier new;"&gt;&lt;span style="font-size:85%;"&gt;Notice: Undefined index: REQUEST_URI in C:\WebSites\PHPSamples\sample_code\section_2\Sajax.php on line 30"&lt;/span&gt;&lt;/blockquote&gt;. Looking at the code, line 30 says: &lt;blockquote style="font-family: courier new;"&gt;&lt;span style="font-size:85%;"&gt;return $_SERVER["REQUEST_URI"];&lt;/span&gt;&lt;/blockquote&gt;Apparently, there seems to be a discrepancy in variables among web servers. In this case, IIS does not recognize REQUEST_URI, instead it recognizes SCRIPT_NAME. I am not quite sure yet on this part but after changing that line, it worked. But I still can't make Sajax work properly on IIS.&lt;br /&gt;&lt;br /&gt;So I decided to run my script on Apache. First task: install and configure Apache. Hmm, again it seems easy with the MSI installer around courtesy of Apache Software Foundation. But again as I'm used with user-friendly auto-configuring installers, I missed some manual configuration required. And when I finally had Apache up and running, I realized that I needed to configure it to run PHP scripts. As I don't know how, I searched the web and stumbled upon &lt;a href="http://www.apachelounge.com/forum/viewtopic.php?t=570"&gt;this one&lt;/a&gt;. That article suggests uninstalling the MSI-installed Apache web server and manually set it up with the procedures it cited. So I followed step by step and voila! It worked! Even the REQUEST_URI variable is defined on Apache. Now I may proceed with learning PHP with Ajax.&lt;br /&gt;&lt;br /&gt;I have two web servers installed on my machine. I am running ASP/ASP.Net scripts on IIS while PHP on Apache. I have yet to find out how I can run both server-side scripting on IIS.&lt;br /&gt;&lt;br /&gt;Lesson learned: Nothing gives a solid foundation than learning the basics. (I had to learn it the hard way.)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115355477658895839?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115355477658895839/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115355477658895839' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115355477658895839'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115355477658895839'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/07/open-source-adventures.html' title='Open Source Adventures'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115275706853768156</id><published>2006-07-13T10:16:00.000+08:00</published><updated>2006-11-14T10:20:59.376+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Resources for Web Development</title><content type='html'>I stumbled upon this &lt;a href="http://www.kayodeok.btinternet.co.uk/favorites/webdesign.htm"&gt;site&lt;/a&gt; containing tons of links for pursuing web development.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115275706853768156?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.kayodeok.btinternet.co.uk/favorites/webdesign.htm' title='Resources for Web Development'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115275706853768156/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115275706853768156' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115275706853768156'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115275706853768156'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/07/resources-for-web-development.html' title='Resources for Web Development'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115210995612008206</id><published>2006-07-05T22:29:00.000+08:00</published><updated>2006-11-14T10:20:59.313+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Re:  Introducing .NET Framework 3.0</title><content type='html'>This &lt;a href="http://msdn.microsoft.com/winfx/default.aspx?pull=/library/en-us/dnlong/html/netfx30.asp"&gt;article&lt;/a&gt;, further describes the new .Net framework (formerly known as WinFX).&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://msdn.microsoft.com/winfx/default.aspx?pull=/library/en-us/dnlong/html/netfx30.asp"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 405px; height: 203px;" src="http://msdn.microsoft.com/library/en-us/dnlong/html/netfx30.gif" alt="" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115210995612008206?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115210995612008206/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115210995612008206' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115210995612008206'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115210995612008206'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/07/re-introducing-net-framework-30.html' title='Re:  Introducing .NET Framework 3.0'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115208269611192233</id><published>2006-07-05T14:47:00.000+08:00</published><updated>2006-11-14T10:20:59.242+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Version Control</title><content type='html'>In my pursuit to monitor my past and present personal projects, I needed to find alternate open-source programs. For version control, a friend recommended SVN. However I also find CVS rather helpful. According to my friend, both are "similar frameworks but with different protocol/implementation." I almost chose the CVS path since it readily has UI; unlike SVN which does not (please correct me if I'm wrong; I'm new to these things). I need to install third party applications: &lt;a href="http://tortoisesvn.tigris.org/"&gt;Tortoise SVN&lt;/a&gt; and Tortoise Merge. Meanwhile, there is also a CVS counterpart: &lt;a href="http://www.tortoisecvs.org/"&gt;Tortoise CVS&lt;/a&gt;. Two great open-source programs. Now, I need to study.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-115208269611192233?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115208269611192233/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115208269611192233' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115208269611192233'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115208269611192233'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/07/version-control.html' title='Version Control'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-115017705056931027</id><published>2006-06-13T13:33:00.000+08:00</published><updated>2006-11-14T10:20:59.166+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Introducing .NET Framework 3.0</title><content type='html'>&lt;span style="font-size:85%;"&gt;I've come across this &lt;a href="http://blogs.msdn.com/somasegar/archive/2006/06/09/624300.aspx"&gt;blog&lt;/a&gt;, and I quote: "With this in mind we have decided to rename WinFX to the .NET Framework 3.0.  .NET Framework 3.0 aptly identifies the technology for exactly what it is – the next version of our developer framework."&lt;br /&gt;&lt;br /&gt;I guess it's just apt for MS to identify WinFX as the next .Net framework, although the structure is very much like (if not is) .Net framework 2.0.&lt;br /&gt;&lt;br /&gt;The framework ships with Windows Vista and shall work well with Windows XP and 2003.&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/24582276-115017705056931027?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://blogs.msdn.com/somasegar/' title='Introducing .NET Framework 3.0'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/115017705056931027/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=115017705056931027' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115017705056931027'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/115017705056931027'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/06/introducing-net-framework-30.html' title='Introducing .NET Framework 3.0'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114965170805824748</id><published>2006-06-07T11:06:00.000+08:00</published><updated>2006-11-14T10:20:59.097+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>DataGrid, DataGridView and DataSource</title><content type='html'>A &lt;span style="font-style: italic;"&gt;challenge&lt;/span&gt; made me recall the differences and similarities between the DataGrid of .Net 1.x and DataGridView of .Net 2.0. Both datasources can be defined with something like:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;dataGrid.DataSource = [object] &lt;datasettable&gt;;&lt;/datasettable&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;The DataGridView control of .Net 2.0 does databinding as simple as that. Although to refresh the contents of the grid, you need to first specify the DataSource as null and then set its datasource property to the data object. (I think you also need to do that for the DataGrid.) But for the DataGrid, you need to have another line of code:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;dataGrid.DataBind();&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Took me a while to recall such syntax. I have been used to .Net 2.0 controls for a while, almost leaving .Net 1.x behind.&lt;br /&gt;&lt;br /&gt;On another note, I'd like to credit a colleague for what I've learned. I helped her out in her thesis (pro bono so to speak), but it turned out that I also benefitted from it. I was able to enhance my backend programming, particularly SQL database access. Before I used the pre-built database objects of Visual Studio (i.e., using the wizard). But I realized that I really didn't have to since I can create my own. Such skill I was able to utilize also in the &lt;span style="font-style: italic;"&gt;challenge&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114965170805824748?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114965170805824748/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114965170805824748' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114965170805824748'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114965170805824748'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/06/datagrid-datagridview-and-datasource.html' title='DataGrid, DataGridView and DataSource'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114961127616563980</id><published>2006-06-07T00:20:00.000+08:00</published><updated>2006-11-14T10:20:59.017+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='IT news'/><title type='text'>Google Homepage</title><content type='html'>I noticed just today that google now enables customization of your home (search) page. You only have to login using your gmail account and go to &lt;a href="http://www.google.com/ig"&gt;http://www.google.com/ig&lt;/a&gt;.  Voila! You can now customize you search page content. It's funny because yesterday, one of our bosses discussed about how boring the original Google search page is. Also, we patterned our web application's main window to Google's so its as boring as its model. But not anymore: Google has now enhanced their website. It's very much less cluttered than Yahoo's; and more importantly, much easier to use.&lt;br /&gt;&lt;br /&gt;Google did it again.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114961127616563980?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.google.com/ig' title='Google Homepage'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114961127616563980/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114961127616563980' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114961127616563980'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114961127616563980'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/06/google-homepage.html' title='Google Homepage'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114911723563162245</id><published>2006-06-01T07:03:00.000+08:00</published><updated>2006-11-14T10:20:58.960+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='open source'/><category scheme='http://www.blogger.com/atom/ns#' term='IT news'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><title type='text'>Microsoft Using Open Source in Vista?</title><content type='html'>It seems that Microsoft is incorporating into Windows Vista a technology called &lt;a href="http://blogs.msdn.com/michael_howard/archive/2006/05/26/608315.aspx"&gt;Address Space Layout Randomization&lt;/a&gt;, which is said to be not an MS innovation.  This security feature is widely used in the open source community to help prevent attacks against the operating system. In fact OpenBSD, as well as some patches for Linux, uses such technology in their OSs. (See the &lt;a href="http://www.answers.com/main/ntquery?s=Address%20Space%20Layout%20Randomization&amp;gwp=16"&gt;wiki&lt;/a&gt; link.)&lt;br /&gt;&lt;br /&gt;Maybe MS doesn't lift source codes, rather just the idea. It's hard to tell for now, especially with MS.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;To find out more about ASLR, go &lt;/span&gt;&lt;a style="font-style: italic;" href="http://pax.grsecurity.net/docs/aslr.txt"&gt;here&lt;/a&gt;&lt;span style="font-style: italic;"&gt;.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114911723563162245?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://blogs.msdn.com/michael_howard/' title='Microsoft Using Open Source in Vista?'/><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114911723563162245/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114911723563162245' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114911723563162245'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114911723563162245'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/06/microsoft-using-open-source-in-vista.html' title='Microsoft Using Open Source in Vista?'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114869650204401631</id><published>2006-05-27T10:10:00.000+08:00</published><updated>2006-11-14T10:20:58.882+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='internet explorer'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='dotnet'/><title type='text'>Default Browser</title><content type='html'>Last week, I reformatted my workstation to be able to integrate our module to the entire project. While I was getting bored waiting for Visual Studio 2005 to finish installing, I tried installing other programs in the background. One of those programs was Firefox, which I eventually set as my default browser. After the VS 2005 installation finished, I set up our web project and tried running it. To my surprise the IDE used Firefox to debug my application instead of IE. (We were developing on IE by the way.)&lt;br /&gt;&lt;br /&gt;So I googled for solutions and wasn't able to find a solution until now. The solution involved using a feature in the IDE which I honestly haven't used before. It's as simple as right-clicking on the start page of the project and Click on "Browse with...". From there I'd select IE as my default browser.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://images.devshed.com/af/stories/How_to_Test/image_6.JPG"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 320px;" src="http://images.devshed.com/af/stories/How_to_Test/image_6.JPG" alt="" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;Got that solution from &lt;a href="http://www.aspfree.com/c/a/ASP.NET/How-to-Test-and-Debug-an-ASPNET-20-Application/3/"&gt;here&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114869650204401631?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114869650204401631/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114869650204401631' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114869650204401631'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114869650204401631'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/05/default-browser.html' title='Default Browser'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114792005668403969</id><published>2006-05-18T10:39:00.000+08:00</published><updated>2006-11-14T10:20:58.811+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='IT news'/><title type='text'>Google Web Toolkit (Beta)</title><content type='html'>Google Web Toolkit (GWT) is a Java development framework that lets you escape the matrix of technologies that make writing AJAX applications so difficult and error prone. With GWT, you can develop and debug AJAX applications in the Java language using the Java development tools of your choice. When you deploy your application to production, the GWT compiler to translates your Java application to browser-compliant JavaScript and HTML.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://code.google.com/webtoolkit/overview.html"&gt;Google Web Toolkit Product Overview&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114792005668403969?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114792005668403969/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114792005668403969' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114792005668403969'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114792005668403969'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/05/google-web-toolkit-beta.html' title='Google Web Toolkit (Beta)'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114679981069472055</id><published>2006-05-05T11:14:00.000+08:00</published><updated>2006-11-14T10:20:58.731+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Re: JavaScript Pointer and Variables</title><content type='html'>To put it simply: Unlike C++ that is Pass-By-Value by default, Java (and consequently, JavaScript) on the other hand is Pass-By-Reference by default. This is the reason why I think there is no counterpart for the &lt;span style="font-style: italic;"&gt;C++ pointer&lt;/span&gt; in Java.&lt;br /&gt;&lt;br /&gt;I recalled this pointer when I was mixed up with using JavaScript clientscript and C# as codebehind.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114679981069472055?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114679981069472055/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114679981069472055' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114679981069472055'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114679981069472055'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/05/re-javascript-pointer-and-variables.html' title='Re: JavaScript Pointer and Variables'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114535324963977353</id><published>2006-04-18T16:34:00.000+08:00</published><updated>2006-11-14T10:20:58.676+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Virtual Memory, Paging, and Working Set</title><content type='html'>These past few days I have been working on performance testing of our project. At a recent meeting with my bosses, they requested me to include memory consumption in our logging aside from mere timing. It is a good idea in fact since we are dealing with serializing chunks of data to and fro the server and client.&lt;br /&gt;&lt;br /&gt;Unfortunately, I need to freshen up a bit on the different types of memory. Apparently there is a &lt;span style="font-style: italic;"&gt;Process &lt;/span&gt;class in dotNet and it has members that can measure virtual, paged, and working set memory of the given process. Since I forgot such terminologies, I googled them and journaled them here. I found their wikis here:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-size:78%;" &gt;&lt;a href="http://en.wikipedia.org/wiki/Working_set"&gt;Working Set&lt;/a&gt; &lt;/span&gt;&lt;span style="font-size:78%;"&gt;is the set of virtual memory pages currently used by the process. The effect of working set size is important and should be neither too large nor too small. If the working set is too large, then fewer processes can never be ready. If the working set is too small, then additional requests must be made of the swapping space to retrieve required pages.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Virtual Memory &lt;/span&gt;or &lt;b&gt;virtual memory addressing&lt;/b&gt; is a memory management technique, used by &lt;a href="http://en.wikipedia.org/wiki/Multitasking" title="Multitasking"&gt;multitasking&lt;/a&gt; &lt;a href="http://en.wikipedia.org/wiki/Computer" title="Computer"&gt;computer&lt;/a&gt; &lt;a href="http://en.wikipedia.org/wiki/Operating_system" title="Operating system"&gt;operating systems&lt;/a&gt; wherein non-contiguous memory is presented to a software application (aka process) as contiguous memory. This contiguous memory is referred to as the &lt;a href="http://en.wikipedia.org/wiki/Virtual_address_space" title="Virtual address space"&gt;virtual address space&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Paging&lt;/span&gt; - In &lt;a href="http://en.wikipedia.org/wiki/Computer" title="Computer"&gt;computer&lt;/a&gt; &lt;a href="http://en.wikipedia.org/wiki/Operating_system" title="Operating system"&gt;operating systems&lt;/a&gt;, &lt;b&gt;paging&lt;/b&gt; &lt;a href="http://en.wikipedia.org/wiki/Memory_allocation" title="Memory allocation"&gt;memory allocation&lt;/a&gt; &lt;a href="http://en.wikipedia.org/wiki/Algorithm" title="Algorithm"&gt;algorithms&lt;/a&gt; divide &lt;a href="http://en.wikipedia.org/wiki/Computer_memory" title="Computer memory"&gt;computer memory&lt;/a&gt; into small partitions, and allocates memory using a &lt;a href="http://en.wikipedia.org/wiki/Page_%28computer_science%29" title="Page (computer science)"&gt;page&lt;/a&gt; as the smallest building block.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114535324963977353?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114535324963977353/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114535324963977353' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114535324963977353'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114535324963977353'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/04/virtual-memory-paging-and-working-set.html' title='Virtual Memory, Paging, and Working Set'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114430361068690919</id><published>2006-04-06T14:04:00.000+08:00</published><updated>2006-11-14T10:20:58.615+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='IT news'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Macs do Windows, too</title><content type='html'>&lt;a href="http://www.apple.com/macosx/bootcamp/"&gt;Boot Camp Public Beta is out&lt;/a&gt;&lt;br /&gt;&lt;span style="font-size:78%;"&gt;(This is slightly off-topic.)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;More and more people are buying and loving Macs. To make this choice simply irresistible, Apple will include technology in the next major release of Mac OS X, Leopard, that lets you install and run the Windows XP operating system on your Mac. Called Boot Camp (for now), you can download a public beta today.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114430361068690919?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114430361068690919/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114430361068690919' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114430361068690919'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114430361068690919'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/04/macs-do-windows-too.html' title='Macs do Windows, too'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114410773661766304</id><published>2006-04-04T07:33:00.000+08:00</published><updated>2006-11-14T10:20:58.560+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Exception Handling</title><content type='html'>It occurred to me while I was watching a &lt;a href="http://www.dnrtv.com"&gt;dnrtv&lt;/a&gt; broadcast (which I recently downloaded from a friend's link) that exception handling is the primary function of the UI. I recalled immediately how our current web project is like: that business-level exceptions are bubbled up to the UI while the UI is the one that knows how to manage such exceptions. While we are indeed implementing such principle, sadly at present, we only open a common popup page that displays the error message. Most of our code is still numb at actually doing something about an exception rather than showing an error message window. I believe that that should not always be the case. At least for a handful of my code, I put a finally statement for each try-catch ones. Usually I put the &lt;span style="font-style: italic;"&gt;fallback&lt;/span&gt; procedures there; not just showing the error message.&lt;br /&gt;&lt;br /&gt;However, there is much work to be done amongst my work and my peers'. We have around two months left.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114410773661766304?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114410773661766304/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114410773661766304' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114410773661766304'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114410773661766304'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/04/exception-handling.html' title='Exception Handling'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114361899615202242</id><published>2006-03-29T14:54:00.000+08:00</published><updated>2006-11-14T10:20:58.501+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Simplest Solution That Could Possibly Work</title><content type='html'>This has always been my objective in almost any work I do. The catch here is that the simplest solution does not always mean it is the easiest one to find. For example, a while ago I was helping out a tpc'er with a rather common and less trivial problem in ASP: validation.&lt;br /&gt;&lt;br /&gt;The problem was to put a validation message beside a required textbox field whenever the submit button was clicked. The question does not even need to involve some ASP syntax in it. A simple JavaScript function will do. The solution I gave was to put a div beside the textbox and then attach a function on the onclick event of the button. The function should look something like this:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;function checkIfEmpty()&lt;br /&gt;{&lt;br /&gt;var txtBox = document.getElementById("txtBox");&lt;br /&gt;if (txtBox != null &amp;&amp;amp; txtBox.value.length &lt; 1)&lt;br /&gt;{&lt;br /&gt;var divMesg = document.getElementById("divMesg");&lt;br /&gt;if (divMesg != null)&lt;br /&gt;{&lt;br /&gt;divMesg.innerHTML = "* (Field is required)";&lt;br /&gt;}&lt;br /&gt;txtBox.click(); // simulate a click&lt;br /&gt;txtBox.select(); // to highlight and focus on the txtBox&lt;br /&gt;}&lt;br /&gt;}&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Somebody else gave a solution that involves posting back. Although that could work, it is not necessarily the best way to go. In my experience in web development (with Ajax and JavaScript in mind), it is almost always better not to post back when client-side scripts do the same job.&lt;br /&gt;&lt;br /&gt;The thread can be found &lt;a href="http://www.tipidpc.com/viewtopic.php?tid=56636"&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;span style=";font-family:georgia;font-size:78%;"  &gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;-Edit: Grammar. Sorry, but I wrote this in a hurry.&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/24582276-114361899615202242?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114361899615202242/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114361899615202242' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114361899615202242'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114361899615202242'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/03/simplest-solution-that-could-possibly.html' title='Simplest Solution That Could Possibly Work'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114319387882394028</id><published>2006-03-24T17:48:00.000+08:00</published><updated>2006-11-14T10:20:58.443+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>Random Ajax Thoughts</title><content type='html'>I found this &lt;a href="http://radio.javaranch.com/pascarello/"&gt;blog&lt;/a&gt; discussing some Ajax issues like those concerning pop-up blockers and sessions. I find this very useful and will check on it from time to time. Especially now that I am on web development &lt;span style="font-style: italic;"&gt;ab&lt;/span&gt;using Ajax.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114319387882394028?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114319387882394028/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114319387882394028' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114319387882394028'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114319387882394028'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/03/random-ajax-thoughts.html' title='Random Ajax Thoughts'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114309973290088930</id><published>2006-03-23T15:35:00.000+08:00</published><updated>2006-11-14T10:20:58.383+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>JavaScript Pointer and Variables</title><content type='html'>I just rediscovered pointer and variable declaration in JavaScript. For instance:&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;var arr1 = new Array();&lt;br /&gt;var arr2 = new Array();&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Here you have to arrays. Each with different elements. In JavaScript you can do something like:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;arr1 =  arr2;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;which is actually making arr1 point or refer to arr2 elements. Thus, any modification in the elements in arr2 will consequently reflect on arr1. So if you want to just copy the initial state of arr2 to arr1 rather than point to it, you must copy each element of the arr2 to arr1 rather than equating them. At the least, the workaround should look something like:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;for (var i in arr2)&lt;br /&gt;{&lt;br /&gt;   arr1[i] = arr2[i];&lt;br /&gt;}&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114309973290088930?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114309973290088930/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114309973290088930' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114309973290088930'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114309973290088930'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/03/javascript-pointer-and-variables.html' title='JavaScript Pointer and Variables'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-24582276.post-114309762981848862</id><published>2006-03-23T15:00:00.000+08:00</published><updated>2006-11-14T10:20:58.326+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>JavaScripts Trivia</title><content type='html'>Apparently there is no overloading in JavaScript. In the past few days I was exhausting myself debugging codes (mine and my teammates') which eventually led me to the realization that there is no function overloading in JavaScript--at least for non-member functions. For instance, in this code assuming that doSomething() is a valid member function:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;function foo(arg1)&lt;br /&gt;{&lt;br /&gt;    doSomething();&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;function foo(arg1, arg2)&lt;br /&gt;{&lt;br /&gt;    doSomething();&lt;br /&gt;}&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;The first foo() will be called and the second one is unreachable. JavaScript will not even warn you if for example you have something like this:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;function foo(arg1, arg2)&lt;br /&gt;{&lt;br /&gt;     doSomething();&lt;br /&gt; }&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;That is, if foo() requires two arguments and you pass only one, it will still call that function without an error.&lt;br /&gt;&lt;br /&gt;Let this be a lesson learned.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/24582276-114309762981848862?l=alexrazon.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://alexrazon.blogspot.com/feeds/114309762981848862/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=24582276&amp;postID=114309762981848862' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114309762981848862'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/24582276/posts/default/114309762981848862'/><link rel='alternate' type='text/html' href='http://alexrazon.blogspot.com/2006/03/javascripts-trivia.html' title='JavaScripts Trivia'/><author><name>Alex</name><uri>http://www.blogger.com/profile/10741593274002428818</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='30' height='32' src='http://i28.photobucket.com/albums/c233/aluxious/alexpsce.jpg'/></author><thr:total>0</thr:total></entry></feed>
