使用Activex控件的使用许可证

xielong 2003-10-15 01:09:43
我在使用vb.net开发个接收电子邮件的程序时,在添加引用中我添加了一个com组件:Msmapi32.ocx,但是在我使用此控件的时候程序却说"您没有使用此Activex控件许可证",Msmapi32.ocx文件是我在网上下载的.请问各位辛苦的程序员朋友,我给怎么解决呢? 谢谢了!非常感谢!
...全文
213 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
lz305 2003-11-01
  • 打赏
  • 举报
回复
学习
xielong 2003-11-01
  • 打赏
  • 举报
回复
谢谢了
楼上的兄弟,我怎么给你分那?谢谢
cnhgj 2003-10-26
  • 打赏
  • 举报
回复
用下列批命令做证书
makecert -sv "denghan.pvk" -n "CN=KinSoft" test.cer
cert2spc test.cer test.spc
---------------------------------------------
用下列命令给CAB文件签名或直接运行signcode.exe
signcode -spc test.spc -v denghan.pvk -n "这个是CAB数字签名" -t

http://timestamp.verisign.com/scripts/timstamp.dll rx80.cab

rx80.CAB文件用rx80.inf的内容

[version]
signature="$CHICAGO$"
AdvancedINF=2.0

[Add.Code]
test.dll=test.dll
rx80.inf=rx80.inf

[test.dll]
file=rx80.cab
RegisterServer=yes
clsid={7E0CDEE7-DC80-4F37-9410-790BB5E9270E}
DestDir=10
FileVersion=1,0,0,1

[rx80.inf]
file=rx80.cab

把这个CAB文件放到你的服务器上,用下列代码说明你的codebase,就会自动下载了。
<object classid="clsid:7E0CDEE7-DC80-4F37-9410-790BB5E9270E" codebase="http://yourHostURL/rx80.cab#version=1,0,0,1" width="800" height="191">
...
Tal 2003-10-25
  • 打赏
  • 举报
回复
数字签名
xielong 2003-10-15
  • 打赏
  • 举报
回复
非常紧急,谢谢了!
xielong 2003-10-15
  • 打赏
  • 举报
回复
能不能用中文给以说明,谢谢了!
Montaque 2003-10-15
  • 打赏
  • 举报
回复
You may need to manually add a runtime license to the ActiveX control:
1. Use aximp to create interop assemblies. (e.g. aximp
/out:C:\temp\AxMyProject.dll C:\Windows\System32\MyProject.ocx)
2. Add reference to the created assemblies in the project (e.g.
AxMyProject.dll (for the AxHost Interop) and MyProject.dll (for COM
Interop))
3. Create the control (e.g. Dim myControl As New
AxMyProject.AxMyLicensedControl())
4. Determine and note the Runtime License Key for the control. (e.g.
"gnvlslnjskvlmlgnnimh").
5. Insert the runtime license into the control.
Dim f As System.Reflection.FieldInfo
f = GetType(AxHost).GetField("licenseKey", _
Reflection.BindingFlags.NonPublic _
Or Reflection.BindingFlags.Instance)
f.SetValue(myControl, "gnvlslnjskvlmlgnnimh")
6. You will need to add the license to every instance of every ActiveX
control that requires a runtime license. So if you were to create a second
instance of MyLicensedControl you would have to add the license to that
instance as well.

One way to determine the license key is with the following KB article:
Q151771 LICREQST.EXE Requesting a License Key from an Object
http://support.microsoft.com/support/kb/articles/q151/7/71.asp

16,552

社区成员

发帖
与我相关
我的任务
社区描述
VB技术相关讨论,主要为经典vb,即VB6.0
社区管理员
  • VB.NET
  • 水哥阿乐
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧