????????C#??????ActiveX???????????????????
????1.?.NET????????COM????
????2.????????????ActiveX????????IE???????
????3.δ????????????????????????IE????????
????????????????????.NET Framework 3.5????????Visual Studio .NET 2008??????.NET Framework 3.5?????????????????
???????????????裺
????????????????COM????????
????????????????COM????????????????????AssemblyInfo.cs???????
????using System.Runtime.InteropServices;
????//???????е??????COM??????
????[assembly: ComVisible(true)]
????// ?????????? COM ???????????? GUID ?????????? ID
????[assembly: Guid("94882155-3B7C-48e3-B357-234D56D8F15E")]
???????????′???AssemblyInfo.cs????????????????
????using System.Security;
????[assembly: AllowPartiallyTrustedCallers()]
????????????Guid????????????????δ???Guid??COM????Guid????????????????Guid??????á?
??????????????????????????IdentityKey.cs??????
using System;
using System.ComponentModel;
using System.Windows.Forms;
using System.Runtime.InteropServices;
namespace KeyActiveX
{
[Guid("94882155-3B7C-48e3-B357-234D56D8F15E")]
public partial class IdentityKey : UserControl
{
}
}
?????????Guid??AssemblyInfo.cs???????????COM????г??CLSID????html??clsid???á?
??????????????У????????????COM?????html????м???
????<object id="controlbyid" classid="clsid:{94882155-3B7C-48e3-B357-234D56D8F15E}" ></object>
??????IE?????ò???????????html??棬???????????????????????????COM?????????????????
???????OLE/COM Object Viewer?????VC???????????.NET Categories?в??????CLSID??