Lol...
Courtsey: TheekHai Dr. Manamohan Singh and Sonia Gandhi
Source: https://www.facebook.com/swami.ramdev
A Weekend blog from Sandeep!
Home » All posts
I’m developing an application for my Windows Phone 7 and today I got an error when I was finally ready to deploy my application on my Phone. I hit deploy and whoa I get an error that “WP7 - Zune software is not launched. Retry after making sure that Zune software is launched.” Sure Zune was opened and connected to my phone alright. It did sync and stuff but still no luck.
Luckily I found about WPConnect.exe found in your “C:\Program Files\Microsoft SDKs\Windows Phone\v7.1\Tools\WPConnect\x86”
Running this again gave ne the same error but at least with an error code 0x80070422
Now we have a little bit more information so I was able to identify the solution.
Due to my very slow system I’m working on I had disabled all the unused System Services and one of them was “zune windows mobile connectivity service”. This Service is used by Visual Studio to connect to your Windows Phone 7.1/7.5 and restarting it fixed it.
So in short if you get an error stating error code 0x80070422 or “WP7 - Zune software is not launched. Retry after making sure that Zune software is launched.” one of the first thing you should try is to enable and start “zune windows mobile connectivity service”
Will be posting my app to Windows Phone Marketplace very soon.
One of the first and most difficult question while you are planning to build your own hosted website is “which CMS to use for my blog/website”. Googling for the best CMS doesn’t help either as all people have their own expertise and comfort level with their recommendation. I too have my bias towards the CMS I chose but since I had no particular experience with any of the CMS I have tried and I’m building it from ground up, it’s applicable to all newbies (I’m primarily a .Net developer so I haven’t worked with other php based CMS and mainly looking for a .Net CMS, people preferring php should use some other reliable resource).
I have tried Wordpress, Joomla, Drupal, DotNetNuke, Kentico, Blog.Net and blogger of course (had tried several others but don’t remember their names). I’ve given them a try multiple times but for one reason or another always comes back to the following two.
Wordpress is one of the best CMS out there, mainly a blogging platform but can easily (and I mean really easy) be extended for website purpose. There are so many themes and modules out there that it simply doesn’t make sense to choose any other if you don’t want to customize via code (which is not a problem if you are a php developer). I prefer .Net so I chose Orchard over wordpress but on every other aspect it’s simply perfect, fast and extensible. You can customize it the way you want and most of it is available from admin interface.
Orchard is ASP.Net/MVC based CMS from Microsoft. It is being actively developed by a very talented team and I’ve seen a lots of improvement over the time in Orchard. Installation is simple. Developing a theme is also easy and you can easily build modules for Orchard (I ‘m still learning it but it’s really good).
If you are looking for a easily setup and extensible CMS for your website, choose one of these two without blinking. They are worth their cost which is free . I love freebies.
For simple blogging purpose blogger.com is also a very good choice. You don’t need to host buy a hosting space for your blog and it allows you to use custom domains (which is a disadvantage for wordpress free hosted blogs).
One CMS I would dis-recommend is DotNetNuke. It’s cumbersome, slow and not very user friendly (my personal opinion ofcourse). It’s highly commercialized and developed in VB.Net and you’ll find a lots of paid modules for DNN as well but since I like freebie I dint find it good. Also it was too slow for my taste when I last tested it (I’ve been using it on shared hosting so that could be a reason for slowness but I can’t afford costly servers not now) so it’s a no-no for me.
Recommendation: No brainer Wordpress (non-developers or php developers)/ Orchard (.net developers)
If you are using Orchard I’d highly recommend TheThemeMachineResponsive theme. It’s a simple responsive theme from the Orchard developers. I’m using it on my beta portal http://backup.sandeeprawat.com which will soon replace my primary domain http://www.sandeeprawat.com
[Update] Forgot to mention another CMS which is very good, light-weight and .Net based. N2 CMS is also very nice to work with. Had worked with it and is very easy and powerful.
If you are bored, sharing a nice song from a very talented singer Rabbi
I came across an interesting problem today.
In our WPF application we are heavily using unity and prism framework and we build pieces of application using unity IModule interfaces. We also make use of EventAggregator.
Now we had a perfectly fine piece of code that was working without any problem so far until today. Here is the code snippet
Note: this is only a sample code to illustrate the problem.
class MyModule:IModule
{
void Initialize(IEventAggregator aggregator)
{
Parameter param = new Parameter();
aggregator.GetEvent<MyEvent>.Subscribe(
() => {SomeStaticMethod(param);});
}
public static void SomeStaticMethod(Parameter param1)
{
//Do Something
}
}
So far so good. Now one of my collegeue made a small change to the code.
class MyModule:IModule
{
ISomeType someTypeObj;
void Initialize(IEventAggregator aggregator, ISomeType someTypeObject)
{
someTypeObj = someTypeObject
Parameter param = new Parameter();
aggregator.GetEvent<MyEvent>.Subscribe(
() => {SomeStaticMethod(param, someTypeObj);});
}
public static void SomeStaticMethod(Parameter param1, ISomeType someTypeObject)
{
//Do Something
}
}
I guess you can see the small difference. We just added a new parameter to the method call in our lambda and whoa our application stops working…
Looking at the change doesn’t give a clue. Why the heck it stopped working with a small change.
Here reflector came to our rescue. After fiddling with our debugger and looking at the reflected code we figured out the issue and it was a very interesting find.
Previously we were only calling a single static method in our lambda and passing a local variable, hence compiler optimized the generated code and produced a static method for our lambda. In the second case though we passed an instance variable and hence generated method had to be an instance method.
Now you must be wondering what difference does it make. But it does when you are using it inside IModule and lambda is used by EventAggregator. By definition IModules are short lived and unless there is a reference to the Module object, it will be garbage collected. Secondly, EventAggregator by default keeps a weak reference to the event handler in the aggregated list. So now since my Module is dead so is my event handler. This event handler was doing stuff, which was life line of my application and hence it went dead too.
Learnings:
You can use Ninja Trader to view historical charts of NSE stocks free of cost. It allows use of free Yahoo finance EOD data. Here is a video showing how to use TCS chart from Yahoo finance. It also supports Goog finance but there is no way Yet to load it into Ninja trade (at least I couldn't get it to work).
For some reasons this video seems to be getting lots of hits in the youtube, so just sharing it on my blog as well. Well just to update my blog..
What is this? Aren't policemen ashamed of what are they doing? (Egyption Police). This kind of brutality can't be tolerated in a civilized world.
Found a good article on the use of goto statements in the languages while, I was following up with posts on stack overflow. Here is a stack overflow post named Goto still considered harmful. It has some interesting discussion but I also found two articles by two great computer scientists discussing it in detail.

Copied from: [http://torrent-finder.info/torrent-finder-domain-seizure.php]
On Thursday, the 25th of November 2010, the Torrent Finder domain ( www.torrent-finder.com ), registered with Godaddy, was seized by the U.S. Immigration and Customs Enforcement (ICE) without any prior takedown notice or specific allegations of infringing activity. The Domain IP was suddenly changed without the registrar's knowledge and the system displayed a "Pending Registry Action" message on the domain's status. No contact was given until Wednesday, the 1st of December, when Godaddy replied to my inquiries, giving a contact for an ICE agent.
On Thursday, the 2nd of December, David Snead who is representing Torrent Finder contacted the ICE agent in charge who told him that "the orders are under seal, but that the seal will be lifted today or tomorrow". However, we have not heard from them until writing this post. Another email from Godaddy clarified that the action was taken by VeriSign: "please understand that these actions were taken by Verisign at the Registry level; and not by Go Daddy". The story was first reported on TorrentFreak and NYTimes.com.
Torrent Finder is a meta search engine that searches other search engines through iframes redirecting users to other domains and websites that Torrent Finder does not manage or control; most of the sites are suggested by Torrent Finder users through URL suggestion form. There have been many explanations about the mechanism of Torrent Finder Search on the media and how it works just like Google or Bing despite that Google does link to .torrent files directly. "So, when is the U.S. Government going to seize the Google domain?" Inquisitr.com asks. And Torrent Freak writes "When a site has no tracker, carries no torrents, lists no copyright works unless someone searches for them and responds just like Google, accusing it of infringement becomes somewhat of a minefield - unless you're ICE Homeland Security Investigations that is" and many others ask the same question, for instance Techdirt and Technobuffalo.com.
…
For more visit: http://torrent-finder.info/torrent-finder-domain-seizure.php
Support electronic freedom, fight censorship. Like the torrent-finder facebook page and spread the news.
As you are aware SharePoint uses a FormDigest to prevent common CSRF attacks.
A Good article on SharePoint XSS and AllowUnsafeUpdates can be found here.
In a relatively obscure scenario you may want to call a SharePoint page asynchronously using AJAX. If so you will want to prevent CSRF attack on the target page and call SPUtility.ValidateFormDigest. But how to provide form digest to this page?
Simple! Just add a __RequestDigest variable to the Post request and call the TargetPage. Don’t forget to include a formdigest control on the TargetPage though or inherit from SharePoint master page.
var canaryValue = document.getElementById('__REQUESTDIGEST').value;
request.Send("__REQUESTDIGEST" +canaryValue+someFormData)
This code is assuming you are making the AJAX call from a SharePoint page which already includes a RequestDigest field and you can use this value to post to the Target Page.Another method to get the request digest is to call GetUpdatedFormDigestInformation method on Sites.asmx webservice.
As an alternative of sending RequestDigest field in the Post Data, you can set the X-RequestDigest header on the web request to the Request Digest value and validate the FormDigest on Target (Couldn’t get it work for the ASPX pages. Works for WebService I believe).
request.SetRequestHeader("X-RequestDigest", canaryValue);
Behind the Code with Anders Hejlsberg
Recommended C# Books
Artist: Alone Dreamer
Error
"the page has one or more <asp:content> that do not correspond with <asp:ContentPlaceHolder> controls in masterpage"
Apparently I’m using a wrong contentPlaceHolderId which doesn’t exist in my master page but that’s not true. Here is my Page
<asp:Content ContentPlaceHolderID="Head" runat="server">
</asp:Content>
<asp:Content ContentPlaceHolderID="Content" runat="server">
</asp:Content>
And my Master page looks like this
<head id="h" runat="server">
<title id="t" runat="server" title='<%$ CurrentPage: Title %>' />
<asp:ContentPlaceHolder ID="Head" runat="server">
<link rel="canonical" href="<%= CurrentPage != null ? CurrentPage.Url : Request.RawUrl %>" />
</asp:ContentPlaceHolder>
</head>
It all looks good to me so where is the problem? Error message is not very friendly in this case and error and solution both seems pretty weird.
Solution: The title tag should not be used as a single closed tag e.g. <title /> instead it should be written as <title></title> and the problem will go away. Look out for other tags as well such as <script />. It doesn’t work very well in the single close tag. Use explicit close tag wherever possible. Browsers are forgiving in nature but not the VS
What to do when you’ve worked hard to integrate Facebook plugins with your website and they look cool on Firefox/Chrome but all of a sudden you feel disappointed when it doesn’t work at all in IE, or may be works sometime but not always (as in my case).
Being an avid IE fan and user, I can’t just sit back and relax when it’s not working on IE. So here is a small modification you need to make to your page when you feel you’ve done everything correct but your fb:like or fb:login-button are still not working.
Add the xmlns:fb namespace to your page and you are done. I just forgot to add this to my page and was living in frustration for one whole day until I came across this post. Then I realized it was a silly mistake and I should’ve added this before when my Visual Studio was complaining about the unrecognized fb tag
<html xmlns:fb="http://www.facebook.com/2008/fbml">
I hope it helps some people implementing Facebook connect on their pages.
This is us playing bowling at Extreme Sports Bar Hyderabad.
Let’s see how we play :)
This is Suneet playing his second best lol..
Now you know how was his first best :) People moved their children away after his ball hit the pins Why?? ‘coz it hit the pins in the another lane… Lol
I was not behind though.. this is how I like to play