Monday, July 22, 2013

Google Drive vs MSFT Skydrive

Cloud storage has become an inevitable aspect for almost every individual. Considering the fact that there are various options available these day, it's pretty tedious to decide which option is best.

After analyzing both the cloud services for quite a while, an honest opinion is that, you can't really zero in to one as the best service. Let's compare Google Drive vs Microsoft's Skydrive here.

To compare both the services, I have considered 3 yardsticks to measure the accountability of each.



Editing:

When we start storing documents in cloud, we don't just store and share but we do consider editing them and expect it to hassle-free and non-tedious process. Google Drive and Microsoft's Skydrive both obviously provide the option of editing the documents. But Skydrive allows editing in the native format of the document but Drive expects you to convert the document to convert it into an intermediate format and then edit it. Since, Microsoft office is a clean solution for office uses, Skydrive provides a clean solution.

In my opinion Microsoft's Skydrive takes a top notch edge over Google Drive

Accessibility:

Accessibility is another important aspect which expect out of a cloud storage system. Both Google and Microsoft provide excellent options to share files. Google includes Drive perfectly to fit in its already existing strong ecosystem. Files sharing is extremely easy to friends and other who have a google account and use any other their product. However, editing can be possible only when the files is in Google format. Skydrive, allows you to share files with anyone even with someone who doesn't have a Skydrive account and editing can be done in a very intuitive manner.

Skydirve again scores over Google Drive

Syncing with Desktop Apps:

Drive and Skydrive have separate apps which would enable syncing with the cloud, however, Drive provides the ability to sync based on the folder that you would like to sync which is not available in Skydrive
 Besides that, Skydrive offers only 7GB of memory to its new users but Google offer 15 GB to its new users.

Points to Google Drive in this segment

Microsoft Skydrive scores 2-1 over Google Drive and is a definite WIN "especially" for people who make a living doing presentations and compiling documents.

Though Box and Dropbox has developed a huge fan following with the unique features, Skydrive is still worth a try. As a matter of fact having an additional free cloud-storage is always a benefit.




Thursday, July 11, 2013

Process holding a file - Process Explorer and more

Its always annoying when we try to delete a file but find out that some process is holding that file which makes the deletion not possible. I have seen a lot of people restarting the PC to kill the process and then try to delete the file.

Process Explorer can come in very handy in identifying the process that is holding a particular file. The Process Explorer will also be useful in identifying the handles and DLLs processes that are opened. 

Downloading and installing the tool is very simple and can be done here. Once you open the Process Explorer, you will find all the processes that are currently running in the machine.
Process Explorer v15.31

If you need to find the process that is holding a file, goto Find -> Find Handle or DLL -> type the entire path of the file and hit search, the tool tell you the process that is preventing the file from deleting.

The Process Explorer displays various other information like, CPU, memory usage and I/O statistic. This can be compared to the task manager with exclusive sophistication.

Trying to delete a file from a piece of code will also encounter such problems and the process explorer could not be used in this situation. We need to kill the process that is holding the file and then try to delete the file.

   
Kill Process that is holding the file


This is the piece of code that can used to kill the process that is folding the file, <fileName>





Friday, July 5, 2013

Mark Pincus reports to Don Mattrick - Potential decision convolution

Zynga once again made, what could be a horrendous decision adding to the mess they are in right now. Zynga recently allured Don Mattrick, Head of Microsoft's Interactive Entertainment division to lead operation in Zynga with a magnum $50 million deal, Mr Mattrick will also be a member of the board of directors. The worst part is here, the out-going CEO and founder Mark Pincus will be the Chief Product Officer and President of the board. So, as far as the org structure stands, Mark will be reporting to Don as a Chief Product Officer and Don in-turn will be reporting to the board where Mark is a Chairman. Who makes the final decision on products and strategies is the big question.

Don Mattrick (Left) and Mark Pincus (right)
                                                     

There is always a potential decision convolution in this scenario. The problem of difference in opinion could never be solved in such a structure. The final decision maker is one of the guys who actually has a difference in opinion and this can eventually result in dirty cold war.

The only way such a structure could work is when Mark and Don have had a good relationship running over a long period of time, which quite possibly is not the case. It will be very interesting to watch the strategical decision that Zynga takes in the near future and the involvement of Don and Mark in it. Mark is the founder and he might have definitive thoughts in leading the company towards one mission. When Don comes in to replace Mark as the CEO and still report to him at the board level, things might turn messy atleast at the early stage. Lets watch out for Zynga's strategical moves in turning around the company from being an underdog into a revenue generating machine...




Tuesday, June 18, 2013

TypeInitialization Exception was unhandled

"TypeInitialization Exception was unhandled"... This was a runtime exception which kept me worried for several hours... Couldn't really understand the actually reason for the RTE which started appearing all of a sudden in a project which was working fine for a long time...

Since it was a very high level exception, nailing down the source of the exception was tricky. To understand the source of the exception, IDE changes had to be made in .NET environment. Go to Debug -> Exception -> check all the "Thrown" exception. This will help in identifying the actually piece of code which throws this unhandled exception.

In my case, I had changed the location of the referenced dlls but the new location was not part of the project. As a result, the dlls were not able to load. Things always get tricky in .Net when you are trying to load a dll from a folder or sub-folder which isn't within the EXECUTABLE location. This would be an interesting read on the topic. But technically, this is just one reason for getting the "TypeInitialization Exception", but the way to probe the problem and get to the source of the same can be very similar to the one explained earlier.

Since, we are talking about this exception I would also like to highlight another reason for it. It may also occur when your "Configuration Manager" is set to "Any CPU" when it is supposed to be just "x86". I have personally not encountered this problem, but there are various posts on stackoverflow, which highlights this example.

Tuesday, July 31, 2012

Microsoft's all new Outlook

Microsoft today launched the all new email service "Outlook" (outlook.com). Microsoft has refurbished its old email service hotmail and gives an absolutely stunning interface. It has a very elegant, simple yet sophisticated interface. It gives a never assumed emailing experience. It has a different strategy to manage all your annoying newsletters which you subscribed out of curiosity.

Outlook also helps you to be "connected" (as VP of cloud services at MSFT calls it). You can see all the information from your social networking accounts and have that right on your email account and actually respond to your friend's comments or photos. Looks like MSFT is making its deal with Facebook count as much as possible. Not to forget "tagging your friends with Bing search" feature, which Microsoft introduced not very long ago.







Interview of Chris Jones, VP cloud services at Microsoft

Techcrunch indicated that Outlook comes with a 7 GB free cloud storage. Even before I logged in to check it out, I assumed MSFT is bringing in its already existing feature of 7 GB free storage it gives with Skydrive and I wasn't wrong. I had to look around for a while though, to learn how to access my Skydrive from outlook.com. However, it is neatly integrated with the email service. You can log-in to outlook.com using your existing Windows Live username or what Microsoft calls as Microsoft Passport. It need not necessarily be a @hotmail.com or a @outlook.com account which is a good thing as no one needs or wants to create a new email address for every email service. You can integrate any of your email accounts with outlook and use outlook.com forever (at least until yet another mind-blowing email service is made available).

Microsoft also promises to integrate skype with the new outlook, which means we will have a gmail video chat experience in outlook (without the delay though :)). The news comes out the day after gmail's announcement of  integrating Google Hangout with gmail (which didn't really make me a happy man). Hope the skype integration doesn't come at an expense of access speed to emails. Though, I feel MSFT has taken a while to get here, I should say it has got here in style. Have to wait and see what would be its strategy to pull Gmail users towards outlook.

The only thing that keeps me worried about this new Outlook is the irrelevant Bing ads in the side bar. I got an immediately reply from an Outlook representative for one of my techcrunch comments  saying "One of the core pillars of Outlook.com is that we don't read your email in order to show you ads. The Bing deals and offers on the right hand side of your inbox are based on the info you provide us; your gender, age, location etc. We're working hard to improve the relevancy of the Bing deals and offers you see, and these will improve over time, but we want to make sure that is not at the expense of your personal privacy. If you'd like to see more relevant Bing deals and offers make sure your account information is up to date with you age, gender, location etc." Though, I should respect the privacy policy of MSFT, I am wondering how could the quality of ads improve by just knowing a person's age, gender, location, etc. May be I am not paying much attention to the word "etc" here. :) Let's wait and watch the game. 

Wednesday, July 25, 2012

HTML Agility Pack

Problems with loading ad parsing HTML file as XML document

Recently I had a situation where I had to parse entire live HTML pages. I implemented it by loading the HTML file as a XMLDocument and parsed it without any problem. It worked perfectly for months until one day when I received an error "XML parsing error at line 46 position 260". I tried analyzing my piece of code but couldn't find anything weird or meaningless. After digging around and hitting the bush around the problem for a while, I figured that the HTML page had an "&" and so XMLDocument was not able to load the document as "&" has an whole different meaning in the XML world. Unfortunately, no XML library gets this right. I tried using various options like XMLResolver, XMLReaderSettings, ValidationOptions, etc to solve the problem but couldn't come up with what I wanted and what would have made me happy.


Problem: The XML DTDs are particularly serious, because DTDs usually include general entity declarations (especially for things like &) which the XML file will rely on. So, if a parser chooses to neglect loading the DTD, and XML makes use of general entity reference, the parser will fail doing the job what it was intended to. The only solution is to create a transparent caching entity resolver, which would put the downloaded files into an archive in the library search path, so that the archive would be dynamically created and automatically bundled with any software distributed. I guess, even in the JAVA world, there isn't an impressive EntityResolver which could do the job (the java gurus shouldn't get pissed off!)

So, I decided to load the HTML just as HTML and parse it. Google introduced me to what is called as HTML Agility pack. This library provides all the necessary methods that a XML namespace has in .Net. Loading and parsing the HTML page was very similar to the XMLDocument parsing, and I altered my parser in no time.



The parsing looks very clean and does the job exactly as how I wanted it to do. 

The code snippet above explains how I loaded the HTML page and parsed it. As you could see, it is as simple as you would parse a XML document. Using the HTML Agility pack, you can also parse the document using LINQ. As of now I am not a huge enthusiast of the LINQ feature in .NET, so I stuck to the traditional parsing methodology.



Wednesday, June 20, 2012

64bit and 32bit compatibility for VS applications

Creating Visual Studio project which are 64bit and 32bit compatible

There is a always a hiccup problem when you are developing applications in 64bits windows machine and deploying it on a 32 bit box. This problem can be fixed in couple mins.

When you are building a new Visual Studio solution or working on an existing project, go to the properties of the solution ---> Configuration Properties ---> select x86 in the Platform dropdown.

Now your application should work on any windows machine irrespective of 64bit or 32bit.