“添加为链接"用于Visual Studio项目中的文件夹 [英] "Add as Link" for folders in Visual Studio projects

查看:115
本文介绍了“添加为链接"用于Visual Studio项目中的文件夹的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Visual Studio中,我们可以添加为链接"将链接添加到解决方案中另一个项目中的文件.

In Visual Studio, we can "Add as link" to add a link to a file in another project in the solution.

是否可以对整个文件夹执行此操作,从而使项目A中的整个文件夹在项目B中可见,而无需手动链接到该文件夹​​中的新项目?

Is there any way to do this for entire folders, so that an entire folder in project A will be visible in project B, without the need to manually link to new items in that folder?

推荐答案

因此

As this blogpost stated, it is possible.

<ItemGroup>
    <Compile Include="any_abs_or_rel_path\**\*.*">
        <Link>%(RecursiveDir)%(FileName)%(Extension)</Link>
    </Compile>
</ItemGroup>

但是请注意,文件不会被复制.

But be aware, the files will not be copied.

这篇关于“添加为链接"用于Visual Studio项目中的文件夹的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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