除了引用方法之外,在projectb中使用projecta中的表单的替代方法 [英] Alternative way for using forms from projecta in projectb other than referencing method

查看:110
本文介绍了除了引用方法之外,在projectb中使用projecta中的表单的替代方法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



我有一个需要在其他项目中使用ProjectA中的vb.net表单的场景。所有这些项目都是单一的解决方案。







我基本上想要消除对这个DLL的依赖。



预先感谢您的协助。



我尝试过:



我知道通过在其他项目中添加对ProjectA的引用来实现这一目标。想知道是否有其他方法可以达到这个目的。

解决方案

不,不是没有复制构成表格的文件 - 这是一个坏的因为这意味着对文件的一个副本的更改可能不会反映在另一个副本中。

这就是引用的目的:允许您从其他项目访问对象而无需重复代码。

Hi All,

I have a scenario where in need to make use of the vb.net forms in ProjectA by other projects. All these projects are under single solution.



I basically want to eliminate the dependency on this DLL.

Thanks in advance for your assistance.

What I have tried:

I know to achieve this by adding reference to ProjectA in other projects. Want to know if there are any other way to achieve this.

解决方案

No, not without duplicating the file(s) that make up the form - which is a bad idea as it means that changes to one copy of the file may not be reflected in the other.
This is what References are there for: to allow you to access objects from other projects without duplication of code.


这篇关于除了引用方法之外,在projectb中使用projecta中的表单的替代方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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