首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 操作系统 > windows >

C#开发的metro app 调用winRT编纂的DLL出错

2012-12-27 
C#开发的metro app 调用winRT编写的DLL出错第一次编写WinRT dll库,namespace mywinrt{public ref class wi

C#开发的metro app 调用winRT编写的DLL出错
第一次编写WinRT dll库,


namespace mywinrt
{
    public ref class winrtWraper sealed
    {
    public:
static property winrtWraper ^ Instance
        {
            winrtWraper ^ get()
            {
                static winrtWraper ^ instance = ref new winrtWraper ();
                return instance;
            }
        }

private:

winrtWraper () { }
    };
}

同时用C#建立一个metro app 的空项目,在项目中创建winrt的导出类对象

mywinrt.winrtWraper wraper = mywinrt.winrtWraper.Instance;

运行程序,出现异常‘System.IO.FileNotFoundException’

怀疑是winrt dll没有被找到,请教解决方法。
[解决办法]
补充下,通过try catch,得到异常的信息是:“The specified module could not be found. ”

热点排行