[UWP]引用Windows运行时组件 [英] [UWP] Referencing Windows runtime components

查看:307
本文介绍了[UWP]引用Windows运行时组件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试从ac sharp Universal应用程序引用c ++ Windows运行时组件(通用),但命名空间不会出现在C sharp应用程序中。

I'm trying to reference a c++ Windows Runtime Component (Universal) from a c sharp Universal app, but the namespace doesn't show up in the C sharp app.

c ++赢取 dowsRuntimeComponent

class1.h

#pragma once

namespace WindowsRuntimeComponent1
{
    public ref class Class1 sealed
    {
    public:
        Class1();
    };
}




class1 .cpp

#include "pch.h"
#include "Class1.h"

using namespace WindowsRuntimeComponent1;
using namespace Platform;

Class1::Class1()
{
}

我添加了对WindowsRuntimeComponent的引用在c sharp通用Windows应用程序中。但是在使用WindowsRuntimeComponent1尝试 "使用"时,它不会显示。

I have added a reference to the WindowsRuntimeComponent In the c sharp Universal Windows App . But it doesn't show up when trying  "using".

using WindowsRuntimeComponent1; //Does not work

我在这里遗漏了什么吗?

Am I missing something here?

推荐答案

JohanD999,

由于您的问题与开发通用Windows应用程序更相关,我将帮助您移动您的帖子可以到相关论坛获得更好的帮助。

感谢您的理解。

致以诚挚的问候,

shu


这篇关于[UWP]引用Windows运行时组件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆