如何注册itextsharp DLL? [英] How do register itextsharp DLL?

查看:263
本文介绍了如何注册itextsharp DLL?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在C#项目中使用itextsharp dll,我需要在Microsoft Access中使用该项目。



我需要能够为它注册dll的工作,但每次我使用regasm.exe我得到RegAsm:警告RA0000:没有类型被注册。



有什么方法可以注册itextsharp或是否有更好的部署我的项目并使用它的方式访问?



我尝试过:



我尝试过使用不同版本的Regasm,我尝试过Regsvr32,但是我发现找不到DIIRegisterServer。



我知道我能够做到它通过Visual Studio注册,但我需要手动执行,以便可以将其部署到最终用户PC。

解决方案

所有公开的类和方法都具有可见性属性。如果textsharp类/方法没有该属性,则可能必须编写一个执行它的包装程序集。



我只是猜测,我对itextsharp一无所知,厌恶MS Access和VBA。


< blockquote class =quote>

Quote:

我在C#项目中使用itextsharp dll,我需要在Microsoft Access中使用该项目。





不确定你需要什么...你想在MS Access中注册itextsharp.dll或c#项目(导出到dll)吗?



如果你想在VBA中使用你的c#项目,我强烈建议你阅读:将.NET Framework组件暴露给COM | Microsoft Docs [ ^ ]



如何为VBA创建一个dll的完整说明,你可以在这里找到:如何在Access或Excel中为VB或VBA创建C#或VB.Net DLL [ ^ ]


I am using itextsharp dll in a C# project and I need to use the project in Microsoft Access.

I need to be able to register the dll's for it to work but everytime I use regasm.exe I get "RegAsm : warning RA0000 : No types were registered".

Is there anything way of registering itextsharp or is there a better way of deploying my project and use it Access?

What I have tried:

I have tried using different versions of Regasm and I tried Regsvr32 but I get "DIIRegisterServer was not found".

I know I am able to do it by registering through Visual Studio but I need to do it manually so it can be deployed to an end users PC.

解决方案

All exposed classes and methods have have the comvisible attribute. If textsharp classes/methods don’t have that attribute, you’ll probably have to write a wrapper assembly that does it.

I’m just guessing, I don’t know anything about itextsharp, and abhor MS Access and VBA.


Quote:

I am using itextsharp dll in a C# project and I need to use the project in Microsoft Access.



Not sure what you need... Do you want to register itextsharp.dll or c# project (exported to dll) in MS Access?

If you want to use your c# project in VBA, i'd strongly recommend to read this: Exposing .NET Framework Components to COM | Microsoft Docs[^]

A complete instruction how to create a dll for VBA, you'll find here: How to create C# or VB.Net DLLs for VB or VBA in Access or Excel[^]


这篇关于如何注册itextsharp DLL?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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