Found the right code from a previous mail and check in them. Support for VS2013.

The old codes were not right. Now the working codes are here.