<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Code Corner</title>
	
	<link>http://CodeCorner.galanter.net</link>
	<description>ASP.NET, XML, SQL and Javascript tips and tricks</description>
	<lastBuildDate>Thu, 09 Feb 2012 22:44:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/galanter/CodeCorner" /><feedburner:info uri="galanter/codecorner" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Correctly apply external styles to UltraWebGrid</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/n386lesPs5A/</link>
		<comments>http://CodeCorner.galanter.net/2012/02/09/correctly-apply-external-styles-to-ultrawebgrid/#comments</comments>
		<pubDate>Thu, 09 Feb 2012 22:44:24 +0000</pubDate>
		<dc:creator>yomgal</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[HTML/CSS]]></category>
		<category><![CDATA[Infragistics]]></category>
		<category><![CDATA[style]]></category>
		<category><![CDATA[trick]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1647</guid>
		<description><![CDATA[Classic Infragistics UltraWebGrid allows you to programmaticaly specify CSS styles for its various elements. For example code like this: Would set style of grid header and rows via external CSS class. You would expect that simple defining classes like this: should do the trick, but you may experience some unwanted, erratic behavior: styles getting lost, [...]]]></description>
			<content:encoded><![CDATA[<p>Classic Infragistics UltraWebGrid allows you to programmaticaly specify CSS styles for its various elements. For example code like this:</p>
<pre class="brush: vb; title: ; notranslate">xmyGrid.DisplayLayout.HeaderStyleDefault.CssClass = &quot;HeaderStyle&quot;
xmyGrid.DisplayLayout.RowStyleDefault.CssClass = &quot;RowStyle&quot;</pre>
<p>Would set style of grid header and rows via external CSS class. You would expect that simple defining classes like this:</p>
<pre class="brush: css; title: ; notranslate">.HeaderStyle {  /* style definition goes here */ }
.RowStyle {  /* style definition goes here */ }</pre>
<p>should do the trick, but you may experience some unwanted, erratic behavior: styles getting lost, styles getting mixed up (row would get a header style and vise versa).</p>
<p>To fix this we should let grid know that header style should apply only to header row (THEAD/TH HTML elements) and row style applies only to rows with data (TBODY/TD elements). This is done via slight adjustments of the above CSS to point it to specific elements:</p>
<pre class="brush: css; title: ; notranslate">THEAD.HeaderStyle TR TH{  /* style definition goes here */ }
TBODY TR TD.RowStyle {  /* style definition goes here */ }</pre>
<p>This way there&#8217;s no confusion, styles apply exactly were they belong. Also you may need to set grids <em>MergeStyles</em> property to <em>False</em> and make each class fully define it&#8217;s element (including fonts, colors, backgrounds etc.)</p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2010/08/09/ultrawebgrid-highlight-row-on-mouseover-with-selection-enabled/" rel="bookmark" class="crp_title">Ultrawebgrid: Highlight row on MouseOver with Selection enabled</a></li><li><a href="http://CodeCorner.galanter.net/2008/09/26/styling-elements-of-infragistics-ultrawebgrid-with-css-classes/" rel="bookmark" class="crp_title">Styling elements of Infragistics UltraWebGrid with CSS Classes</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/CIAxwaRfMo-A6SZp_qP_hfRCkOM/0/da"><img src="http://feedads.g.doubleclick.net/~a/CIAxwaRfMo-A6SZp_qP_hfRCkOM/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/CIAxwaRfMo-A6SZp_qP_hfRCkOM/1/da"><img src="http://feedads.g.doubleclick.net/~a/CIAxwaRfMo-A6SZp_qP_hfRCkOM/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/n386lesPs5A" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/02/09/correctly-apply-external-styles-to-ultrawebgrid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/02/09/correctly-apply-external-styles-to-ultrawebgrid/</feedburner:origLink></item>
		<item>
		<title>D-Link DIR-655: How to make 1.35 firmware upgrade stick</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/aD4RQQryqNk/</link>
		<comments>http://CodeCorner.galanter.net/2012/02/06/link-dir-655-how-to-make-1-35-firmware-upgrade-stick/#comments</comments>
		<pubDate>Tue, 07 Feb 2012 04:24:25 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[New Stuff]]></category>
		<category><![CDATA[Rant]]></category>
		<category><![CDATA[network]]></category>
		<category><![CDATA[solution]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1640</guid>
		<description><![CDATA[If you&#8217;re trying to upgrade your D-Link DIR-655 Extreme-N Gigabit Wireless Router to the latest firmware (1.35NA US version as of this post), you may encounter a weird problem: firmware uploads without errors, router says it is being reprogrammed, but after reboot old version is displayed. To solve it &#8211; try following these steps Save [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re trying to upgrade your <a href="http://www.amazon.com/gp/product/B000LIFB7S/ref=as_li_qf_sp_asin_tl?ie=UTF8&amp;tag=yuriygalanshomeo&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=B000LIFB7S" title="D-Link DIR-655 Extreme-N Gigabit Wireless Router">D-Link DIR-655 Extreme-N Gigabit Wireless Router</a> to the latest firmware (1.35NA US version as of this post), you may encounter a weird problem: firmware uploads without errors, router says it is being reprogrammed, but after reboot old version is displayed.</p>
<p>To solve it &#8211; try following these steps</p>
<ol>
<li>Save your current settings (Tools -&gt; System -&gt; Save Configuration) &#8211; you should do it prior any update anyway</li>
<li>This what does the trick: On the same screen click &#8220;Restore Factory Default&#8221; &#8211; this will restore router default settings (one more reason why it&#8217;s important to do the update over wired connection)</li>
<li>Flash your firmware</li>
<li>Restore setting saved in Step 1 and reboot the router</li>
<li><del>Profit!</del> You&#8217;re now on the latest firmware<br />
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2012/01/06/cyanogenmod-on-kindle-fire/" rel="bookmark" class="crp_title">CyanogenMod on Kindle Fire</a></li><li><a href="http://CodeCorner.galanter.net/2011/12/19/how-to-comfortably-read-pdf-books-on-kindle-fire/" rel="bookmark" class="crp_title">How to comfortably read PDF books on Kindle Fire</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/Mv6PtlzzOr62PQvDPqNqVLYBA8M/0/da"><img src="http://feedads.g.doubleclick.net/~a/Mv6PtlzzOr62PQvDPqNqVLYBA8M/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/Mv6PtlzzOr62PQvDPqNqVLYBA8M/1/da"><img src="http://feedads.g.doubleclick.net/~a/Mv6PtlzzOr62PQvDPqNqVLYBA8M/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/aD4RQQryqNk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/02/06/link-dir-655-how-to-make-1-35-firmware-upgrade-stick/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/02/06/link-dir-655-how-to-make-1-35-firmware-upgrade-stick/</feedburner:origLink></item>
		<item>
		<title>Visual Basic FTW!</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/GIJzxMnm_T4/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/23/visual-basic-ftw/#comments</comments>
		<pubDate>Mon, 23 Jan 2012 20:56:45 +0000</pubDate>
		<dc:creator>yomgal</dc:creator>
				<category><![CDATA[Humor]]></category>
		<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[funny]]></category>
		<category><![CDATA[stupid]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1637</guid>
		<description><![CDATA[I knew modern VB was a powerful language, but had no idea it could do this: Create GUI to track IP in real-time email&#8230; what would they think of next? Related Posts:Plants vs. Zombies 2!Apple commercial for Windows 7]]></description>
			<content:encoded><![CDATA[<p>I knew modern VB was a powerful language, but had no idea it could do this:</p>
<object width="600" height="400"><param name="movie" value="hkDD03yeLnU"></param><param name="wmode" value="transparent" ></param><embed src="http://www.youtube.com/v/hkDD03yeLnU" type="application/x-shockwave-flash" wmode="transparent" width="600" height="400"></embed></object>
<p>Create GUI to track IP in real-time email&#8230; what would they think of next?</p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2011/12/10/plants-vs-zombies-2/" rel="bookmark" class="crp_title">Plants vs. Zombies 2!</a></li><li><a href="http://CodeCorner.galanter.net/2009/10/23/apple-commercial-for-windows-7/" rel="bookmark" class="crp_title">Apple commercial for Windows 7</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/fQ9_zVD9f4PEaCEvHP-KU1tEopU/0/da"><img src="http://feedads.g.doubleclick.net/~a/fQ9_zVD9f4PEaCEvHP-KU1tEopU/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/fQ9_zVD9f4PEaCEvHP-KU1tEopU/1/da"><img src="http://feedads.g.doubleclick.net/~a/fQ9_zVD9f4PEaCEvHP-KU1tEopU/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/GIJzxMnm_T4" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/23/visual-basic-ftw/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/23/visual-basic-ftw/</feedburner:origLink></item>
		<item>
		<title>@@ROWCOUNT is affected by IF statement</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/puRdbOzTyKg/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/19/rownumber-is-affected-by-if-statement/#comments</comments>
		<pubDate>Thu, 19 Jan 2012 20:03:19 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[SQL]]></category>
		<category><![CDATA[Data]]></category>
		<category><![CDATA[Quick fix]]></category>
		<category><![CDATA[solution]]></category>
		<category><![CDATA[workaround]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1629</guid>
		<description><![CDATA[Let&#8217;s say you&#8217;re writing T-SQL code and need to make sure that your query returns one and only row. If no records returned &#8211; an error message needs to be shown. If more than one record is returned &#8211; another error message needs to be show. The code goes something like this: Now if your [...]]]></description>
			<content:encoded><![CDATA[<p>Let&#8217;s say you&#8217;re writing T-SQL code and need to make sure that your query returns one and only row. If no records returned &#8211; an error message needs to be shown. If more than one record is returned &#8211; another error message needs to be show. The code goes something like this:</p>
<pre class="brush: sql; title: ; notranslate">-- ... query runs here and returns row

IF @@ROWCOUNT = 0 RAISERROR('No records found', 18, 1)
ELSE IF @@ROWCOUNT &gt; 0 RAISERROR('More than one record found', 18, 1)

-- ... continue when exactly one row is returned</pre>
<p>Now if your query returns 3 records you&#8217;d expect it to trip the second IF statement and raise error with correct message. Unfortunately this doesn&#8217;t happen. The reason being &#8211; the first IF statement resets @@ROWCOUNT to 0. So, to avoid this we need to preserve the @@ROWCOUNT value in a local variable:</p>
<pre class="brush: sql; title: ; notranslate">DECLARE @iRowCount int

-- ... query runs here and returns row

SET @iRowCount = @@ROWCOUNT

IF @iRowCount = 0 RAISERROR('No records found', 18, 1)
ELSE IF @iRowCount &gt; 0 RAISERROR('More than one record found', 18, 1)

-- ... continue when exactly one row is returned</pre>
<p>This way count of rows returned by the query is saved and is not affected by any following statements.</p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2011/04/22/solution-for-previoussibling-is-null-or-not-an-object-error-in-grouped-ultrawebgrid/" rel="bookmark" class="crp_title">Solution for &#8216;previousSibling&#8217; is null or not an object error in grouped UltraWebGrid</a></li><li><a href="http://CodeCorner.galanter.net/2008/05/07/dynamic-number-of-fields-in-a-query-for-ssrs-2005/" rel="bookmark" class="crp_title">Dynamic number of fields in a query for SSRS 2005</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/zl1ymFVBK2jEq-Qvt9fgRQjL8FE/0/da"><img src="http://feedads.g.doubleclick.net/~a/zl1ymFVBK2jEq-Qvt9fgRQjL8FE/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/zl1ymFVBK2jEq-Qvt9fgRQjL8FE/1/da"><img src="http://feedads.g.doubleclick.net/~a/zl1ymFVBK2jEq-Qvt9fgRQjL8FE/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/puRdbOzTyKg" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/19/rownumber-is-affected-by-if-statement/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/19/rownumber-is-affected-by-if-statement/</feedburner:origLink></item>
		<item>
		<title>UltraWebGrid TopItemSpacing=”Auto”: Solution for FireFox</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/QuF0dH56ba8/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/12/ultrawebgrid-topitemspacing-auto-solution-for-firefox/#comments</comments>
		<pubDate>Thu, 12 Jan 2012 21:46:40 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[HTML/CSS]]></category>
		<category><![CDATA[Infragistics]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[design]]></category>
		<category><![CDATA[solution]]></category>
		<category><![CDATA[style]]></category>
		<category><![CDATA[trick]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1621</guid>
		<description><![CDATA[If you&#8217;re still using classic Infragistics Controls and want to make them work in modern browsers, sometimes a little additional work is required. Hopefully this little trick will save you some time. UltraWebGrid has a neat property TopItemSpacing, when set to Auto it automatically spreads top level menu items across the menu control, giving them [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re still using classic Infragistics Controls and want to make them work in modern browsers, sometimes a little additional work is required. Hopefully this little trick will save you some time.</p>
<p>UltraWebGrid has a neat property <em>TopItemSpacing</em>, when set to <em>Auto</em> it automatically spreads top level menu items across the menu control, giving them nice spacing in between. Unfortunately this property seems to work in Internet Explorer only, in Firefox (and Chrome and etc.) it is ignored, rendering menu in <em>Compact</em> mode giving top level items crowded &#8220;too-close-for-comfort&#8221; look.</p>
<p>The solution is to take spacing in our own hands. Set <em>TopItemSpacing</em> to <em>Compact</em> and instead add right padding to <em>TopLevelParentItemStyle</em> and <em>TopLevelLeafItemStyle</em> elements of the menu. For example (from the markup point of view):</p>
<pre class="brush: xml; highlight: [2]; title: ; notranslate">&lt;TopLevelLeafItemStyle Cursor=&quot;Hand&quot; Height=&quot;18px&quot; BorderWidth=&quot;1px&quot; Font-Size=&quot;8pt&quot;&gt;
   &lt;Padding Right=&quot;6px&quot; /&gt;
&lt;/TopLevelLeafItemStyle&gt;</pre>
<p>Actual pixel value of the padding is up to your particular scenario, but the final result is top level menu items will be nicely spaced both in IE and in Firefox.</p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2011/12/06/ultrawebmenu-when-background-doesnt-change-on-hover/" rel="bookmark" class="crp_title">UltraWebMenu: When background doesn&#8217;t change on hover in IE9</a></li><li><a href="http://CodeCorner.galanter.net/2011/02/24/infragistics-webdatamenu-csom-additemremoveitem-workaround/" rel="bookmark" class="crp_title">Infragistics WebDataMenu CSOM addItem/removeItem workaround</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/PkRFa6o224LjWod8hh4Lp2wbXwU/0/da"><img src="http://feedads.g.doubleclick.net/~a/PkRFa6o224LjWod8hh4Lp2wbXwU/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/PkRFa6o224LjWod8hh4Lp2wbXwU/1/da"><img src="http://feedads.g.doubleclick.net/~a/PkRFa6o224LjWod8hh4Lp2wbXwU/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/QuF0dH56ba8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/12/ultrawebgrid-topitemspacing-auto-solution-for-firefox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/12/ultrawebgrid-topitemspacing-auto-solution-for-firefox/</feedburner:origLink></item>
		<item>
		<title>ICS: Android 4 on Kindle Fire</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/7g4dQPsxirI/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/11/ics-android-4-on-kindle-fire/#comments</comments>
		<pubDate>Thu, 12 Jan 2012 02:34:39 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[New Stuff]]></category>
		<category><![CDATA[cool]]></category>
		<category><![CDATA[design]]></category>
		<category><![CDATA[Google]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1610</guid>
		<description><![CDATA[Another day, another experiment on my new favorite toy business instrument &#8211; Kindle Fire. Today I went ahead and installed latest (as of this date) incarnation of Android OS &#8211; version 4 aka Ice Cream Sandwich (ICS). Again, like in case with CyanogenMod 7 (which is essentially Android 2.3.7) installation is extremally easy thanks to [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://kitchen.galanter.net/sitepic/ICSonKindleFire.jpg" alt="Ice Cream Sandwitch on Kindle Fire" align="left" style="padding-right:10px" /></p>
<p>Another day, another experiment on my new favorite <del>toy</del> business instrument &#8211; <a href="http://www.amazon.com/gp/product/B0051VVOB2?ie=UTF8&amp;tag=yuriygalanshomeo&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=B0051VVOB2" title="Amazon Kindle Fire">Kindle Fire</a>. Today I went ahead and installed latest (as of this date) incarnation of Android OS &#8211; version 4 aka Ice Cream Sandwich (ICS). Again, like in case with <a href="http://codecorner.galanter.net/2012/01/06/cyanogenmod-on-kindle-fire/" title="CyanogenMod on Kindle Fire" target="_blank">CyanogenMod 7</a> (which is essentially Android 2.3.7) installation is extremally easy thanks to TWRP recovery. Just download <a href="http://forum.xda-developers.com/showthread.php?t=1430160" title="Kindle Zone ICS ROM" target="_blank">Kindle Zone ICS ROM</a> put it on your Fire, reboot into TWRP recovery, <strong>*backup your existing rom*</strong> and flash the ICS.</p>
<p>It boots nicely and looks pretty good. Connects to WiFi with Internet and LAN access (ES File Explorer comes preinstalled and accessed SMB shares on my home network with no problems).</p>
<p>Being a very early version it has it share of problems. Video doesn&#8217;t work correctly (MP4 files for example play in fast-forward mode, YouTube can&#8217;t connect). Sounds work sporadically and overall moving around the interface has a jerky feeling. But it looks like a very good start and I am looking forward to a more stable release. Meanwhile I am back to CM7 </p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2012/01/06/cyanogenmod-on-kindle-fire/" rel="bookmark" class="crp_title">CyanogenMod on Kindle Fire</a></li><li><a href="http://CodeCorner.galanter.net/2011/12/16/kindle-fire-as-an-android-tablet/" rel="bookmark" class="crp_title">Kindle Fire as an Android Tablet</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/uB6dPWPc4JpxGbW3giGDotbEwKA/0/da"><img src="http://feedads.g.doubleclick.net/~a/uB6dPWPc4JpxGbW3giGDotbEwKA/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/uB6dPWPc4JpxGbW3giGDotbEwKA/1/da"><img src="http://feedads.g.doubleclick.net/~a/uB6dPWPc4JpxGbW3giGDotbEwKA/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/7g4dQPsxirI" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/11/ics-android-4-on-kindle-fire/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/11/ics-android-4-on-kindle-fire/</feedburner:origLink></item>
		<item>
		<title>How to add threshold line to MSChart in ASP.NET</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/gOB28ddp8Ek/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/10/how-to-add-threshold-line-to-mschart-in-asp-net/#comments</comments>
		<pubDate>Tue, 10 Jan 2012 20:35:19 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[chart]]></category>
		<category><![CDATA[design]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[solution]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1601</guid>
		<description><![CDATA[Often, when drawing a chart, there&#8217;s a need to show a threshold &#8211; basically a line that indicates whether your values are going above or below it. Take for example this ColumnChart: Let&#8217;s say we need to show a threshold for the value of 7. Here&#8217;s how. MSChart API supports several Annotation objects, we&#8217;re interested [...]]]></description>
			<content:encoded><![CDATA[<p>Often, when drawing a chart, there&#8217;s a need to show a <em>threshold</em> &#8211; basically a line that indicates whether your values are going above or below it. Take for example this ColumnChart:</p>
<p><img src="http://kitchen.galanter.net/sitepic/ChartWithoutThreshold.png" alt="Chart Without Threshold" /></p>
<p>Let&#8217;s say we need to show a threshold for the value of 7. Here&#8217;s how.<span id="more-1601"></span> </p>
<p>MSChart API supports several <em>Annotation</em> objects, we&#8217;re interested in <em>HorizontalLineAnnotation</em>. Take a look at the following code:</p>
<pre class="brush: vb; title: ; notranslate">Dim oHla As New HorizontalLineAnnotation()

With oHla

    .AxisX = xmsChart.ChartAreas(0).AxisX
    .AxisY = xmsChart.ChartAreas(0).AxisY
    .ClipToChartArea = xmsChart.ChartAreas(0).Name
    .IsInfinitive = True

    .AnchorY = 7
    .LineWidth = 3
    .LineColor = Drawing.Color.Red
    .LineDashStyle = ChartDashStyle.Dot

End With

xmsChart.Annotations.Add(oHla)</pre>
<ul>
<li><em>Line 1</em> creates HorizontalLineAnnotation object</li>
<li><em>Lines 5, 6, 7</em> assocciate the annotation with chart area</li>
<li><em>Line 8</em> makes sure that annotation line stretches thru entire chart</li>
<li><em>Line 10</em> assigns our threshold value</li>
<li><em>Lines 11, 12, 13</em> set the style of the annotation line</li>
<li><em>Line 17</em> adds annotation we created to the chart</li>
</ul>
<p>The result:</p>
<p><img src="http://kitchen.galanter.net/sitepic/ChartWithThreshold.png" alt="Chart With Threshold" /></p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2010/01/06/serving-mschart-via-webservice/" rel="bookmark" class="crp_title">Serving image from ASP.NET MSChart to external applications via WebService</a></li><li><a href="http://CodeCorner.galanter.net/2009/05/19/global-chart-type-for-dundas-chart-control/" rel="bookmark" class="crp_title">Global Chart Type for Dundas Chart Control</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/RxTuhFBkUWzfpzNo3tvu4vpRuq0/0/da"><img src="http://feedads.g.doubleclick.net/~a/RxTuhFBkUWzfpzNo3tvu4vpRuq0/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/RxTuhFBkUWzfpzNo3tvu4vpRuq0/1/da"><img src="http://feedads.g.doubleclick.net/~a/RxTuhFBkUWzfpzNo3tvu4vpRuq0/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/gOB28ddp8Ek" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/10/how-to-add-threshold-line-to-mschart-in-asp-net/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/10/how-to-add-threshold-line-to-mschart-in-asp-net/</feedburner:origLink></item>
		<item>
		<title>WebDataGrid: Prevent scrolling on row selection</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/8CA4LDa6v9Y/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/09/webdatagrid-prevent-scrolling-on-row-selection/#comments</comments>
		<pubDate>Mon, 09 Jan 2012 20:39:14 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[Infragistics]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[solution]]></category>
		<category><![CDATA[workaround]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1592</guid>
		<description><![CDATA[If you working with Infragistics Aikido controls and your WebDataGrid or WHDG is too long &#8211; a common approach to make content scrollable is to place grid control inside of a DIV with fixed dimensions and overflow set to auto: It works fine, but there&#8217;s one drawback: if you scroll your grid horizontally and then [...]]]></description>
			<content:encoded><![CDATA[<p>If you working with Infragistics Aikido controls and your WebDataGrid or WHDG is too long &#8211; a common approach to make content scrollable is to place grid control inside of a DIV with fixed dimensions and overflow set to auto:</p>
<p><img src="http://kitchen.galanter.net/sitepic/ScrollableGrid.png" alt="WHDG scrollable inside of parent DIV" /></p>
<p>It works fine, but there&#8217;s one drawback: if you scroll your grid horizontally and then select a row &#8211; grid&#8217;s scroll position snaps back to the leftmost position. Infragistics says that it&#8217;s a browser bug and we need to talk to browser vendor about it. Wanting to solve the problem in this century I looked for alternatives and this is what I found.<span id="more-1592"></span></p>
<p>To avoid the shift in scroll position we need to cancel the scroll event. Doing it directly (adding handler to &#8220;onscroll&#8221; event and canceling it there) is impossible since event is uncancelable (is it even a word?). Instead we can catch grid&#8217;s &#8220;RowSelectionChanging&#8221; event and cancel event bubble there:</p>
<pre class="brush: jscript; title: ; notranslate">function xMyGrid_RowSelectionChanging(sender, eventArgs) {
   event.cancelBubble = true
}</pre>
<p>of course a better, more compatible approach would be:</p>
<pre class="brush: jscript; title: ; notranslate">function xMyGrid_RowSelectionChanging(sender, eventArgs) {
   eventArgs.getBrowserEvent().stopPropagation();
}</pre>
<p>but unfortunately &#8220;eventArgs.getBrowserEvent()&#8221; is <em>null</em> in this case and we have to resort to first approach. This method still allows rows to be selected but cancels scroll to the left after selection.</p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2010/01/06/delaying-selectedindexchanged-event/" rel="bookmark" class="crp_title">Delaying SelectedIndexChanged event of ComboBox in VB.NET WinForm</a></li><li><a href="http://CodeCorner.galanter.net/2010/07/08/how-todisable-hyperlink-clicks/" rel="bookmark" class="crp_title">How to Disable hyperlink clicks</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/YDmQQDUsEc7a5b7k7sFRmWklx9Q/0/da"><img src="http://feedads.g.doubleclick.net/~a/YDmQQDUsEc7a5b7k7sFRmWklx9Q/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/YDmQQDUsEc7a5b7k7sFRmWklx9Q/1/da"><img src="http://feedads.g.doubleclick.net/~a/YDmQQDUsEc7a5b7k7sFRmWklx9Q/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/8CA4LDa6v9Y" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/09/webdatagrid-prevent-scrolling-on-row-selection/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/09/webdatagrid-prevent-scrolling-on-row-selection/</feedburner:origLink></item>
		<item>
		<title>CyanogenMod on Kindle Fire</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/UtKo9FMeibE/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/06/cyanogenmod-on-kindle-fire/#comments</comments>
		<pubDate>Sat, 07 Jan 2012 02:51:03 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Rant]]></category>
		<category><![CDATA[bug]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1584</guid>
		<description><![CDATA[Lately I&#8217;ve been posting a lot about Kindle Fire and no wonder &#8211; I love this tablet and tweaking with it. Today I went to tweaking extreme &#8211; installed a custom ROM, namely CyanogenMod. CyanogenMod is famous for being a better replacement ROM for a wide multitude of Android devices from Droid phones to Nook [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://kitchen.galanter.net/sitepic/CyanogenModOnKindleFire.png" alt="CyanogenMod on Kindle Fire" align="left" style="padding-right:10px" /> Lately I&#8217;ve been <a href="http://codecorner.galanter.net/?s=Kindle+Fire" title="Kindle Fire" target="_blank">posting a lot</a> about <a href="http://www.amazon.com/gp/product/B0051VVOB2?ie=UTF8&amp;tag=yuriygalanshomeo&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=B0051VVOB2" title="Kindle Fire">Kindle Fire</a> and no wonder &#8211; I love this tablet and tweaking with it.</p>
<p>Today I went to tweaking extreme &#8211; installed a custom ROM, namely CyanogenMod. CyanogenMod is famous for being a better replacement ROM for a wide multitude of Android devices from Droid phones to Nook tablets. And finally it made its way to Kindle Fire. Installing it turned out to be surprisingly easy &#8211; first, using <a href="http://forum.xda-developers.com/showthread.php?t=1399889" title="Kindle Fire Utility" target="_blank">Kindle Fire Utility</a> root your Fire and install TWRP Recovery &#8211; very useful instrument not only for installing new ROMs but also for backing up and restoring your existing one in case something goes wrong. Second, download <a href="http://forum.xda-developers.com/showthread.php?t=1390773" title="CyanogenMOD @ XDA" target="_blank">latest CyanogenMod</a> in form of &#8220;update.zip&#8221; and place into temp/download folder of your Fire. And lastly reboot into TWRP recovery, browse for the ZIP and install it.</p>
<p>CyanogenMod didn&#8217;t let down, it was perfect as usual &#8211; fast, highly customizable, this one specifically build for Fire with its lack of hardware buttons. It has many wonderful features (for example picture in this post is, unlike previous posts, is a direct screenshot from my Fire, &#8220;take a screenshot&#8221; is one of the options appearing in menu when you press and hold power button).</p>
<p>It has everything. The only drawback for me is, for the love of it, I couldn&#8217;t make Amazon Instant Video app work in this mod. The issue is widely discussed on the Interwebs, multiple possible solutions are offered, but none worked for me. And since Prime Instant Videos is the only original Fire feature that I use &#8211; I had to return back to rooted stock Amazon ROM with ADW launcher (thanks TWRP for making ROM backup and recovery a very simple experience). Until working version of Amazon Instant Video is bundled with Cyanogen &#8211; I am keeping the stock.<br />
<span id="more-1584"></span></p>
<hr />
<em>UPDATE:</em> Actually I realized that I *can* watch Amazon Instant Videos on the CyanogenMod by simple browsing to Amazon Website (in my case using Dolphin Browser HD)</p>
<p><img src="http://kitchen.galanter.net/sitepic/AmazonVideo1.jpg" alt="Prime Videos on Amazon Website" /></p>
<p>and watching them using Amazon&#8217;s in-browser Flash player</p>
<p><img src="http://kitchen.galanter.net/sitepic/AmazonVideo2.jpg" alt="Prime Videos in Amazon Flash player" /></p>
<p>Quality turned out to be surprisingly good, maybe it&#8217;s due to hardware accelerated video playback in in CM7, maybe something else, but the fact is that Prime Videos can be played on modded, rooted Fire. So I am back to Cyanogen, and it&#8217;s worth every kilobyte. As an added bonus &#8211; all Market apps that were incompatible with Fire and refused to install &#8211; now can be installed.</p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2012/01/11/ics-android-4-on-kindle-fire/" rel="bookmark" class="crp_title">ICS: Android 4 on Kindle Fire</a></li><li><a href="http://CodeCorner.galanter.net/2011/12/16/kindle-fire-as-an-android-tablet/" rel="bookmark" class="crp_title">Kindle Fire as an Android Tablet</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/35fyDWDUnTPL3pVORGOEdFvzl_U/0/da"><img src="http://feedads.g.doubleclick.net/~a/35fyDWDUnTPL3pVORGOEdFvzl_U/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/35fyDWDUnTPL3pVORGOEdFvzl_U/1/da"><img src="http://feedads.g.doubleclick.net/~a/35fyDWDUnTPL3pVORGOEdFvzl_U/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/UtKo9FMeibE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/06/cyanogenmod-on-kindle-fire/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/06/cyanogenmod-on-kindle-fire/</feedburner:origLink></item>
		<item>
		<title>Russian Keyboard on Kindle Fire</title>
		<link>http://feedproxy.google.com/~r/galanter/CodeCorner/~3/wtbef2lKP1E/</link>
		<comments>http://CodeCorner.galanter.net/2012/01/05/russian-keyboard-on-kindle-fire/#comments</comments>
		<pubDate>Fri, 06 Jan 2012 03:54:31 +0000</pubDate>
		<dc:creator>Yuriy</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[cool]]></category>
		<category><![CDATA[solution]]></category>

		<guid isPermaLink="false">http://CodeCorner.galanter.net/?p=1573</guid>
		<description><![CDATA[It used to be a bit of a pain to install a 3rd party keyboard on Kindle Fire &#8211; you had to work with SQL Lite and ADB Shell and there were a few other requirements. But thanks to Tivan from samsung-tablets.com it&#8217;s down to 3 easy steps (one requirement remains: Your Kindle Fire has [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://kitchen.galanter.net/sitepic/RussianKeyboardOnKindleFire.jpg" alt="Russian Keyboard on Kindle Fire" /></p>
<p>It used to <a target="_blank" href="http://www.addictivetips.com/mobile/install-alternate-keyboard-apps-on-kindle-fire-how-to/" title="Old way of installing 3rd party keyboard on Kindle Fire">be a bit of a pain</a> to install a 3rd party keyboard on <a href="https://www.amazon.com/dp/B0051VVOB2/ref=as_li_tf_til?tag=yuriygalanshomeo&amp;camp=0&amp;creative=0&amp;linkCode=as1&amp;creativeASIN=B0051VVOB2&amp;adid=1VQSBN73FDSDGX8NY1ET&amp;" title="Kindle Fire">Kindle Fire</a> &#8211; you had to work with SQL Lite and ADB Shell and there were a few other requirements. But thanks to <a href="http://www.samsung-tablets.com/amazon-kindle-fire-toturial-install-alternative-keyboards.html/" title="New and easy way to install 3rd party keyboard on Kindle Fire" target="_blank">Tivan from samsung-tablets.com</a> it&#8217;s down to 3 easy steps (one requirement remains: Your <a href="https://www.amazon.com/dp/B0051VVOB2/ref=as_li_tf_til?tag=yuriygalanshomeo&amp;camp=0&amp;creative=0&amp;linkCode=as1&amp;creativeASIN=B0051VVOB2&amp;adid=1VQSBN73FDSDGX8NY1ET&amp;" title="Kindle Fire">Kindle Fire</a> has to be rooted with Android Market app installed).<span id="more-1573"></span></p>
<p>So, to install Russian Keyboard on your Kindle Fire, follow these steps:</p>
<ol>
<li>Install <a href="https://market.android.com/details?id=ru.androidteam.rukeyboard" title="Russian Keyboard from GameWarrior" target="_blank">great Russian Keyboard app</a> from the Market</li>
<li>Using any file manager with root access (ES File Explorer or Root Explorer) copy file <strong>ru.androidteam.rukeyboard.apk</strong> from folder <strong>/data/app</strong> to <strong>/system/app</strong> and then reboot your device.</li>
<li>Using file manager again, click the APK file in the new location to install it and then delete it from the new location</li>
</ol>
<p>That&#8217;s it! After that keyboard behaves like on any other Android device &#8211; if you press and hold any text input area &#8211; you will be prompted to &#8220;Choose input method&#8221; and one of the choices will be Russian Keyboard.</p>
<hr />
<strong>UPDATE!!!</strong> Turned out there&#8217;s an <em>even easier</em> approach and it doesn&#8217;t even required root! Yakov Shafranovich developed a <a target="_blank" href="http://www.shaftek.org/blog/2011/12/03/enabling-other-languages-on-amazons-new-kindle-fire-tablet/" title="Native Russian support on Kindle Fire">small ingenious app</a> (using Google App Inventor no less) that unlocks Fire&#8217;s own multilanguage support &#8211; no 3rd party apps needed. Just download it from the Market (or, in absence of the Market &#8211; directly from author site), run it and select all the keyboards you need (many languages are supported, don&#8217;t forget to include English as well). Then when keyboard is activated &#8211; change layout by simple swipe over the space bar. Thanks Yakov!</p>
<div id="crp_related"><h4>Related Posts:</h4><ul><li><a href="http://CodeCorner.galanter.net/2011/12/16/kindle-fire-as-an-android-tablet/" rel="bookmark" class="crp_title">Kindle Fire as an Android Tablet</a></li><li><a href="http://CodeCorner.galanter.net/2012/01/11/ics-android-4-on-kindle-fire/" rel="bookmark" class="crp_title">ICS: Android 4 on Kindle Fire</a></li></ul></div>
<p><a href="http://feedads.g.doubleclick.net/~a/4I55NjDsUWyZrv_xBX7qb2dZgdY/0/da"><img src="http://feedads.g.doubleclick.net/~a/4I55NjDsUWyZrv_xBX7qb2dZgdY/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/4I55NjDsUWyZrv_xBX7qb2dZgdY/1/da"><img src="http://feedads.g.doubleclick.net/~a/4I55NjDsUWyZrv_xBX7qb2dZgdY/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/galanter/CodeCorner/~4/wtbef2lKP1E" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://CodeCorner.galanter.net/2012/01/05/russian-keyboard-on-kindle-fire/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://CodeCorner.galanter.net/2012/01/05/russian-keyboard-on-kindle-fire/</feedburner:origLink></item>
	</channel>
</rss>

