Hi Amit,
I just bumped into the same issue today, and here is the fix I found.
Edit the header file (.h, you can actually open it with Matlab, back up the original one just in case), and delete the ' extern "C" ' part in the # define line. Then call loadlibrary with the new header.
According to https://stackoverflow.com/questions/2288293/windows-c-extern-declspecdllimport and https://stackoverflow.com/questions/1041866/what-is-the-effect-of-extern-c-in-c it might give issues with the function naming, check using libfunctions, I did not see any problem with my library.
Good luck, I'll let you know if I get something wrong at some point.