我想创建一个dll [英] I want to create a dll

查看:66
本文介绍了我想创建一个dll的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想为已经开发的Windows应用程序项目创建一个dll文件吗?
表示我已经创建了Windows应用程序.现在我想将此项目用于其他项目.如果我为此创建dll,肯定会用到其他一些文件.



我在开发的应用程序中观察到只有exe文件,没有dll

I want to create a dll file for already developed windows application project?
means i have created windows application. now i want to use this project to some other. if i create dll for this definitely i will use to some other.



i observed in developed application in that has exe file only ,no dll

How can i make it n how can i use it?

推荐答案

将Windows应用程序转换为Library Dll

参加新的班级项目.将粘贴的表单代码复制到新类中
删除以下代码...
Covert Windows Application to Library Dll

take the new class Project. Copy paste Form code into new class
remove the below code...
<pre lang="cs">public partial class Form1 : Form
  {
      public Form1()
      {
          InitializeComponent();
      }





添加此..,





Add this.. ,

public class <yourclassname>
   {</yourclassname>


请参阅下面链接中的答案.

我要创建一个dll适用于已开发的Windows应用程序 [
refer to my answer on the link below.

i want to create a dll for developed windows app[^]


是基于.Net Framework构建的Windows应用程序.
如果是:

Sol 1:如果您有源代码,那么将其转换为DLL并不是什么大挑战.
Sol 2:您可以使用
is your windows application built on .Net Framework..,

If Yes :

Sol 1: If you have Source code, i thing that is not big challenge to convert as a DLL.
Sol 2: you can directly use methods in the exe using Refelction[^]


这篇关于我想创建一个dll的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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