How to Delete an Azure Active Directory when Facing the Enterprise Application Deletion Error

Recently, I got a strange issue when trying to delete an Azure Active Directory I created: it kept asking me to “Delete all Enterprise Applications” even the Enterprise application list is empty after I clicks the suggested link. After filing a support ticket and trying many different suggested things, finally a solution worked for me …

How to Build Microsoft Graph Engine on Red Hat Linux

Microsoft Graph Engine is a distributed in-memory data processing engine. It’s an open source project but the official instructions claim that for Linux, it only supports Ubuntu 16.04. But what if you’re using other distributions of Linux, like Red Hat? Well, it’s possible but it does take quite some effort to build the source. Let’s get …

ExpectedExceptionBaseAttribute and “Object reference not set to an instance of an object”

You’re writing unit tests with Visual Studio and you want to verify that you’re throwing the correct Exception. You could use ExpectedExceptionAttribute class but it only allows you to verify the type of the Exception. You might want to verify other properties so you decide to create a subclass of ExpectedExceptionBaseAttribute, which allows you to have …

Programmatically Paste Clipboard Text to a CMD Window (C# or C++)

To accomplish this, I have tried different approaches: posting WM_PASTE, SendKeys sending ctrl-v… None of the method seems to be working so well. A friend from work suggested trying WM_COMMAND. Since Spy++ doesn’t work with cmd.exe, we had to use brute force to find the correct WPARAM for pasting. The result is really simple, just one line code with C++: // hwnd …

Me in A Magic Session

Other than being a software developer, I am also a magician. Check out this blog post (you will probably have difficulties understanding some of the magic jargon if you are not a magician): http://nnylfmit.blogspot.com/2009/06/no-way-jose.html.