<?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-7375052518078238440</id><updated>2012-02-17T06:00:35.116+02:00</updated><category term='c#'/><category term='mvc'/><category term='aspnet'/><category term='ansi-c'/><category term='JQuery'/><category term='sqlserver'/><category term='android'/><category term='on the shoulders of giants'/><category term='clr'/><category term='python'/><category term='os'/><category term='ajax'/><category term='howto'/><category term='admob'/><category term='DynamicData'/><category term='collections'/><category term='design-patterns'/><category term='JavaScript'/><category term='django'/><category term='fcl'/><category term='json'/><title type='text'>day and night blog</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>19</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-3704563311803322866</id><published>2011-05-19T15:25:00.000+03:00</published><updated>2011-05-19T15:25:55.104+03:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='json'/><category scheme='http://www.blogger.com/atom/ns#' term='android'/><title type='text'>JSON on Android</title><summary type='text'>google-gson is the best JSON library I've seen so far.

Let's say JSON is something like this:
[{"id":2,"lon":-3.51984,"address":"McArthur Glen Designer Outlet, Almondvale Avenue, Livingston",
 * "name":"Livingston","postcode":"EH54 6QX", "url":"http:\/\/new.myvue.com\/latest-movies\/cinema\/livingston\/?
 * &amp;utm_campaign=XMLGateway&amp;utm_source=iphone&amp;utm_medium=Website&amp;p=iphone","lat":55.88248},
</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/3704563311803322866/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=3704563311803322866' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/3704563311803322866'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/3704563311803322866'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2011/05/json-on-android.html' title='JSON on Android'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-5827752890479366314</id><published>2011-05-19T15:18:00.003+03:00</published><updated>2011-05-19T15:26:23.395+03:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='android'/><category scheme='http://www.blogger.com/atom/ns#' term='admob'/><title type='text'>AdMob issued an undocumented update to their Android SDK</title><summary type='text'>The recent Android AdMob SDK update includes GoogleAdMobAdsSdk-4.1.0.jar and a new way of configuration is required. However, as of time of writing, this has not been documented yet on Google/AdMob official site. 

Just replacing the old jar with the new one gives the following error: "AdView missing required XML attribute "adSize". " 

Here is the solution explained by a Google employee:
1) </summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/5827752890479366314/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=5827752890479366314' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5827752890479366314'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5827752890479366314'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2011/05/admob-issued-undocumented-update-to.html' title='AdMob issued an undocumented update to their Android SDK'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-7224115500290787851</id><published>2011-05-12T09:38:00.000+03:00</published><updated>2011-05-13T23:44:42.030+03:00</updated><title type='text'>Moldova Republic can now buy apps from Google store</title><summary type='text'>Moldova just has been added  to the list of the countries were you can buy paid applications on Android Market.</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/7224115500290787851/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=7224115500290787851' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7224115500290787851'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7224115500290787851'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2011/05/moldova-republic-can-now-buy-apps-from.html' title='Moldova Republic can now buy apps from Google store'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-367425215248925771</id><published>2011-05-12T09:37:00.000+03:00</published><updated>2011-05-13T23:44:42.059+03:00</updated><title type='text'>I'm back</title><summary type='text'>I'm back.</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/367425215248925771/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=367425215248925771' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/367425215248925771'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/367425215248925771'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2011/05/im-back.html' title='I&apos;m back'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-4444899055512927920</id><published>2010-05-23T10:12:00.001+03:00</published><updated>2010-05-23T10:14:27.100+03:00</updated><title type='text'>How to adjust brightness with vlc media player?</title><summary type='text'>To adjust brightness on vlc media player:

Select menu item Tools -&gt; Effects and Filters,  choose tab Video Effects.</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/4444899055512927920/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=4444899055512927920' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/4444899055512927920'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/4444899055512927920'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2010/05/how-to-adjust-brightness-with-vlc-media.html' title='How to adjust brightness with vlc media player?'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-7284927945565947124</id><published>2009-02-26T13:54:00.012+02:00</published><updated>2010-03-14T09:44:41.138+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='JavaScript'/><category scheme='http://www.blogger.com/atom/ns#' term='JQuery'/><category scheme='http://www.blogger.com/atom/ns#' term='django'/><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><title type='text'>minor touches</title><summary type='text'>Some minor changes could be made to the Ajax live bookmark search example on page 109 of the book Learning Website Development with DjangoFirst, at the end of bookmark_list.html we could add the same condition check as in search.html in order to avoid displaying 'No bookmarks found' message when searching for an empty string:...{% else %} {% if show_results %}   No bookmarks found. {% endif %} {%</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/7284927945565947124/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=7284927945565947124' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7284927945565947124'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7284927945565947124'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2009/02/minor-touches.html' title='minor touches'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-887045256788276104</id><published>2009-02-25T09:56:00.011+02:00</published><updated>2010-03-14T09:49:09.289+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='django'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><title type='text'>Learning Website Development with Django errata</title><summary type='text'>The book Learning Website Development with Django has been written for Django 0.96. In my spare time I am following its code while using Django 1.0 and making corrections where(hopefully) it seems appropriate.On page 104 instead of ...if request.GET.has_key('query'):    show_results = True    query = request.GET['query'].strip()    if query:      form = SearchForm({'query' : query})       </summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/887045256788276104/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=887045256788276104' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/887045256788276104'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/887045256788276104'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2009/02/learning-website-development-with_25.html' title='Learning Website Development with Django errata'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-6955132279116512286</id><published>2009-02-04T10:52:00.021+02:00</published><updated>2009-03-05T13:32:00.804+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='django'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><title type='text'>о книге Learning Website Development with Django</title><summary type='text'>Книга неплохая но есть и некоторые нестыковки. Необычно выглядит использование __str__ в моделях вместо настоятельно рекомендуемого __unicode__.(см. Choosing between __str__() and __unicode__()) Книга показалась интересной поэтому продолжил чтение сверяя код из книги с документацией. Вскоре наткнулся на следущую незавершенность. Вот модель которую предлагает автор(после замены __str__ на __</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/6955132279116512286/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=6955132279116512286' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/6955132279116512286'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/6955132279116512286'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2009/02/learning-website-development-with.html' title='о книге Learning Website Development with Django'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-5759293239184183204</id><published>2009-01-28T15:59:00.005+02:00</published><updated>2009-02-24T09:03:28.452+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='django'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><title type='text'>Зачистка</title><summary type='text'>До выхода NetBeans 7.0 Milestone2  с поддержкой Django и чисткой проекта осталось больше двух недель. Несмотря на то что чистить Питон проект особой нужды нет, привычка, похоже, действительно вторая натура. Поэтому :#!/usr/bin/env python#----------------------------------------------------#use ';' to separate the extentions if more than one,#for example: pattern = "*.pyc;*.doc;*.txt"#all of the </summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/5759293239184183204/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=5759293239184183204' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5759293239184183204'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5759293239184183204'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2009/01/blog-post.html' title='Зачистка'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-758215017692545644</id><published>2008-12-26T10:35:00.004+02:00</published><updated>2008-12-26T10:39:42.418+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='os'/><category scheme='http://www.blogger.com/atom/ns#' term='howto'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><title type='text'>List environment variables from Python</title><summary type='text'>To print the list of environment variables use the following code:import osfor param in os.environ.keys():    print "%20s %s" % (param,os.environ[param])</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/758215017692545644/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=758215017692545644' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/758215017692545644'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/758215017692545644'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/12/to-print-list-of-environment-variables.html' title='List environment variables from Python'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-5608074596553226862</id><published>2008-11-27T09:41:00.018+02:00</published><updated>2008-11-29T08:59:39.289+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='howto'/><category scheme='http://www.blogger.com/atom/ns#' term='aspnet'/><title type='text'>Cross-page posts and OnClientClick</title><summary type='text'>The Button.OnClientClick property is a convenient way of executing additional client side script when the Click event is raised.For example, after clicking the following button :&lt;asp:Button ID="Button1" runat="server" OnClientClick="return confirm('Are You Sure?');" Text="Button" Width="125px" /&gt;a confirmation dialog will pop up:If the confirmation box returns false, the button click is canceled.</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/5608074596553226862/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=5608074596553226862' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5608074596553226862'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5608074596553226862'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/11/cross-page-posts-and-onclientclick.html' title='Cross-page posts and OnClientClick'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_EuYnIZLnMtM/SS5XV-U0AdI/AAAAAAAAAH8/ECcMGbUg25w/s72-c/Clipboard01.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-5644243418415374464</id><published>2008-11-12T15:30:00.012+02:00</published><updated>2008-11-14T23:09:14.421+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='howto'/><category scheme='http://www.blogger.com/atom/ns#' term='DynamicData'/><title type='text'>Custom Templates for Dynamic Data Web Application</title><summary type='text'>While following the MSDN documentation on DynamicData found myself stuck on How to: Customize the Layout of an Individual Table By Using a Custom Page Template.After copying List.aspx to the CustomPages folder the project just would not compile:The naming collision is obvious and I couldn't believe my eyes - the MSDN article seemed to be incorrect.Solution: the MSDN article is written for a </summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/5644243418415374464/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=5644243418415374464' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5644243418415374464'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5644243418415374464'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/11/custom-templates-for-dynamic-data-web.html' title='Custom Templates for Dynamic Data Web Application'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_EuYnIZLnMtM/SRrc3yAh5fI/AAAAAAAAAH0/Qa2AZXtBFBc/s72-c/Clipboard01.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-9008154639533260601</id><published>2008-11-07T10:32:00.012+02:00</published><updated>2008-11-14T23:16:15.052+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='design-patterns'/><category scheme='http://www.blogger.com/atom/ns#' term='collections'/><category scheme='http://www.blogger.com/atom/ns#' term='fcl'/><title type='text'>NVI pattern (again)</title><summary type='text'>There was an example of the Non Virtual Interface pattern in a previous post . Time has come to show its use in the FCL. Technically speaking, the Collection&lt;T&gt; class is not a demonstration of using of the NVI per se, but still an incentive to apply the pattern in your own code.After deriving from System.Collections.ObjectModel.Collection&lt;T&gt; you have exactly the same functionality as in a List&lt;T&gt;</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/9008154639533260601/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=9008154639533260601' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/9008154639533260601'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/9008154639533260601'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/11/nvi-pattern-again.html' title='NVI pattern (again)'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-6399389403209430335</id><published>2008-11-03T10:10:00.004+02:00</published><updated>2008-11-03T11:41:32.928+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c#'/><category scheme='http://www.blogger.com/atom/ns#' term='ansi-c'/><title type='text'>ANSI C and C# bit-fields comparison</title><summary type='text'>We can achieve storage space saving in ANSI C by one of the following means:1. define a set of bit-field masks:#define MONDAY 01#define TUESDAY 02#define WEDNESDAY 042. declare an enum with bit-fields:enum { MONDAY = 01, TUESDAY = 02, WEDNESDAY = 03};/*turn on Monday and Wednesday:*/days |= MONDAY | WEDNESDAY;/*turn off Monday and Wednesday:*/days &amp;= ~(MONDAY | WEDNESDAY);/*is true if Monday and </summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/6399389403209430335/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=6399389403209430335' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/6399389403209430335'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/6399389403209430335'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/11/ansi-c-and-c-bit-fields-comparison.html' title='ANSI C and C# bit-fields comparison'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-8336790328860646467</id><published>2008-10-29T17:17:00.008+02:00</published><updated>2008-10-29T17:44:52.930+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='howto'/><category scheme='http://www.blogger.com/atom/ns#' term='sqlserver'/><title type='text'>Restore a SQL Server  2005 Express database from a *.bak file</title><summary type='text'>How to restore a SQL Express 2005 database from an existing *.bak to an *.mdf file:1. download and install SQL Server Management Studio from the official site  or use the direct link2. right click on 'Databases' folder in the Object Explorer, choose restore database.3. under 'Specify the source and location of backup sets to restore' choose 'From device', click on browse button, add your bak file</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/8336790328860646467/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=8336790328860646467' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/8336790328860646467'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/8336790328860646467'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/10/restore-sql-server-2005-express.html' title='Restore a SQL Server  2005 Express database from a *.bak file'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-7018696536100455860</id><published>2008-10-27T11:44:00.001+02:00</published><updated>2008-11-03T13:46:37.460+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='clr'/><category scheme='http://www.blogger.com/atom/ns#' term='c#'/><title type='text'>Wait and Pulse fun</title><summary type='text'>If you want two threads to increment a variable in an alternating manner, a nice way of doing it could be the following:    class EntryPoint {        static private int counter = 0;        static private object theLock = new Object();                static private void ThreadFunc1() {            lock (theLock) {                for (int i = 0; i &lt; 50; ++i) {                    Monitor.Wait(theLock</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/7018696536100455860/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=7018696536100455860' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7018696536100455860'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7018696536100455860'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/10/wait-and-pulse-fun.html' title='Wait and Pulse fun'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_EuYnIZLnMtM/SQg57qWUbqI/AAAAAAAAAG8/k8zpzY54KHw/s72-c/Clipboard01.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-5133589880353107957</id><published>2008-10-21T12:24:00.006+03:00</published><updated>2008-10-22T14:44:26.645+03:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='on the shoulders of giants'/><category scheme='http://www.blogger.com/atom/ns#' term='mvc'/><title type='text'>MVC's UpdateModel function and the AcceptVerbs attribute(unrelated)</title><summary type='text'>After you create your new model object within the controller action, you want to populate its properties with the corresponding values from the FormCollection, right? If for example you have a model Message class:    public class Message {                public Message() { }        public Message(int id, string author, string subject, string body) {            this.Id = id;            this.Author</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/5133589880353107957/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=5133589880353107957' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5133589880353107957'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/5133589880353107957'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/10/after-you-create-your-new-model-object.html' title='MVC&apos;s UpdateModel function and the AcceptVerbs attribute(unrelated)'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-7296071023601500201</id><published>2008-10-18T11:24:00.004+03:00</published><updated>2008-10-21T13:16:05.409+03:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='howto'/><category scheme='http://www.blogger.com/atom/ns#' term='mvc'/><title type='text'>Upgrading from MVC preview 5 to MVC Beta</title><summary type='text'>Here is what I did to my toy project to make it work under MVC Beta:1. Removed reference to Microsoft.Web.Mvc.dll.2. Set 'Copy Local' option to true for the System.Web.Mvc.dll.3. Added &lt;add namespace="System.Web.Mvc.Html"/&gt;to the namespaces section of Web.config.</summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/7296071023601500201/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=7296071023601500201' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7296071023601500201'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/7296071023601500201'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/10/upgrade-from-microsoft-mvc-preview-5-to.html' title='Upgrading from MVC preview 5 to MVC Beta'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7375052518078238440.post-2092810772040465434</id><published>2008-10-15T21:47:00.013+03:00</published><updated>2008-10-15T23:17:51.224+03:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='design-patterns'/><category scheme='http://www.blogger.com/atom/ns#' term='on the shoulders of giants'/><category scheme='http://www.blogger.com/atom/ns#' term='c#'/><title type='text'>Non-Virtual Interface Pattern</title><summary type='text'>An interesting design pattern found in chapter 13 of "Accelerated C# 2008" by Trey Nash.Suppose after writing and delivering your base class to thousands of users you want some pre and/or post work done.Instead of introducing two more methods, PreDoWork() and PostDoWork() and asking your users to reimplement their overrides to call these new methods on the correct time, use the Non-Virtual </summary><link rel='replies' type='application/atom+xml' href='http://dhrcoding.blogspot.com/feeds/2092810772040465434/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7375052518078238440&amp;postID=2092810772040465434' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/2092810772040465434'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7375052518078238440/posts/default/2092810772040465434'/><link rel='alternate' type='text/html' href='http://dhrcoding.blogspot.com/2008/10/non-virtual-interface-pattern.html' title='Non-Virtual Interface Pattern'/><author><name>Dumitru Hristov</name><uri>http://www.blogger.com/profile/11356397762878819267</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry></feed>
