{"provider_url":"https://hatena.blog","description":"DllImport\u3067\u6587\u5b57\u5217\u3092\u6e21\u3059\u5834\u5408\u3001\u4f55\u306e\u6587\u5b57\u30b3\u30fc\u30c9\u3067\u30a8\u30f3\u30b3\u30fc\u30c9\u3055\u308c\u308b\u3079\u304d\u306a\u3093\u3067\u3057\u3087\u3046\u304b\uff1f \u4f8b\u3048\u3070\u3001 \u30d5\u30a1\u30a4\u30eb\uff1afoo.c #include <stdio.h> __declspec(dllexport) void Say(const char* msg) { printf(\"say \u300c%s\u300d\\n\", msg); } \u30b3\u30f3\u30d1\u30a4\u30eb\u3057\u3066\u3001foo.dll\u3092\u4f5c\u308a\u307e\u3057\u305f\u3002 > cl /LD foo.c \u3067\u3001\u3053\u3044\u3064\u3092P/Invoke\u3067C#\u304b\u3089\u547c\u3073\u51fa\u3057\u307e\u3059\u3002 \u30d5\u30a1\u30a4\u30eb\uff1abar.cs using System; using System.Text; using System.Runtime.InteropSe\u2026","type":"rich","blog_url":"https://akiramei.hatenadiary.org/","width":"100%","image_url":null,"html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fakiramei.hatenadiary.org%2Fentry%2F20041125%2F1\" title=\"CharSet.Ansi\u3067\u6e21\u3055\u308c\u308b\u3082\u306e\u306f\uff1f - \u5323\u306e\u5411\u3053\u3046\u5074 - \u3042\u307e\u308a\u306b.NET\u306a\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","blog_title":"\u5323\u306e\u5411\u3053\u3046\u5074 - \u3042\u307e\u308a\u306b.NET\u306a","author_name":"akiramei","title":"CharSet.Ansi\u3067\u6e21\u3055\u308c\u308b\u3082\u306e\u306f\uff1f","author_url":"https://blog.hatena.ne.jp/akiramei/","published":"2004-11-25 09:00:01","height":"190","categories":["Mono","C#","Code"],"version":"1.0","provider_name":"Hatena Blog","url":"https://akiramei.hatenadiary.org/entry/20041125/1"}