funini.com 自由研究 C# .NET

VC++

DLL のインポート

Visual Studio 2010 で dll をインポートして実行したら、以下のエラー。
Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call.  This is usually a result of calling a function declared with one calling convention with a function pointer declared with a different calling convention.
関数の呼び出し方式が違うらしい。
http://yamatyuu.net/computer/program/sample/dll/index.html

Wstring と std::string の変換

C 言語では、"abc" と書いた文字列は null terminate で、 ... Visual C++ では、 C++