473,702 Members | 2,357 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

is it possible to create Activex Component using c#.net? If yes then how to create it?<EOM>



Nov 17 '05 #1
6 8672
check out the following:

http://www.codeproject.com/cs/miscct...etcontrols.asp

HTH

Ollie Riches

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:Oi******** ******@TK2MSFTN GP10.phx.gbl...

Nov 17 '05 #2
No it's not possible to author ActiveX controls in C#, there is however a
possibility to 'expose' Window Forms controls as ActiveX controls through
the CLR COM interop layer. Note that while the CLR doesn't offer all
features of "full controls "(see OC96 specs.) WF controls can be exposed as
ActiveX controls in ActiveX containers like IE and Office.
Willy.

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:Oi******** ******@TK2MSFTN GP10.phx.gbl...

Nov 17 '05 #3
Hi Willy,

Do ur workaround allow me to fire regsvr32 command on the dll?
If yes, then I have to use this registered dll as excel RTD server.

Waiting for reply...
Thanks,
Deepak

"Willy Denoyette [MVP]" <wi************ *@telenet.be> wrote in message
news:eG******** *****@TK2MSFTNG P10.phx.gbl...
No it's not possible to author ActiveX controls in C#, there is however a
possibility to 'expose' Window Forms controls as ActiveX controls through
the CLR COM interop layer. Note that while the CLR doesn't offer all
features of "full controls "(see OC96 specs.) WF controls can be exposed
as ActiveX controls in ActiveX containers like IE and Office.
Willy.

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:Oi******** ******@TK2MSFTN GP10.phx.gbl...


Nov 17 '05 #4
You don't need regsvr32, you need to include the functions to register the
UC as an "AX control" in the registry as explained in the article pointed to
by Ollie, when done you should register the assembly as COM callable using
regasm.exe, or by setting the project property "register for COM interop".
Note that exposing .NET to COM clients requires .NET to be installed!.

Willy.

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:el******** ******@TK2MSFTN GP14.phx.gbl...
Hi Willy,

Do ur workaround allow me to fire regsvr32 command on the dll?
If yes, then I have to use this registered dll as excel RTD server.

Waiting for reply...
Thanks,
Deepak

"Willy Denoyette [MVP]" <wi************ *@telenet.be> wrote in message
news:eG******** *****@TK2MSFTNG P10.phx.gbl...
No it's not possible to author ActiveX controls in C#, there is however a
possibility to 'expose' Window Forms controls as ActiveX controls through
the CLR COM interop layer. Note that while the CLR doesn't offer all
features of "full controls "(see OC96 specs.) WF controls can be exposed
as ActiveX controls in ActiveX containers like IE and Office.
Willy.

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:Oi******** ******@TK2MSFTN GP10.phx.gbl...



Nov 17 '05 #5
Hi Willy,

Thanks for your valuable help.
I simply created a class library in c# project and inside configuration
prpoerties tab, i checked for "register for COM interop".
Does it solve my pb? Because I have to create a "excel RTD server" and for
this dll should be of activex dll type.

Regards,
Deepak
"Willy Denoyette [MVP]" <wi************ *@telenet.be> wrote in message
news:O0******** ******@tk2msftn gp13.phx.gbl...
You don't need regsvr32, you need to include the functions to register the
UC as an "AX control" in the registry as explained in the article pointed
to by Ollie, when done you should register the assembly as COM callable
using regasm.exe, or by setting the project property "register for COM
interop".
Note that exposing .NET to COM clients requires .NET to be installed!.

Willy.

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:el******** ******@TK2MSFTN GP14.phx.gbl...
Hi Willy,

Do ur workaround allow me to fire regsvr32 command on the dll?
If yes, then I have to use this registered dll as excel RTD server.

Waiting for reply...
Thanks,
Deepak

"Willy Denoyette [MVP]" <wi************ *@telenet.be> wrote in message
news:eG******** *****@TK2MSFTNG P10.phx.gbl...
No it's not possible to author ActiveX controls in C#, there is however
a possibility to 'expose' Window Forms controls as ActiveX controls
through the CLR COM interop layer. Note that while the CLR doesn't offer
all features of "full controls "(see OC96 specs.) WF controls can be
exposed as ActiveX controls in ActiveX containers like IE and Office.
Willy.

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:Oi******** ******@TK2MSFTN GP10.phx.gbl...



Nov 17 '05 #6

"B Deepak" <de**********@p ersistent.co.in > wrote in message
news:u5******** ******@TK2MSFTN GP10.phx.gbl...
Hi Willy,

Thanks for your valuable help.
I simply created a class library in c# project and inside configuration
prpoerties tab, i checked for "register for COM interop".
Does it solve my pb? Because I have to create a "excel RTD server" and for
this dll should be of activex dll type.

Regards,
Deepak


If your only need is to use the RTD function in Excel, then, all you have to
do is to expose the .NET class as a COM server, and all you have to do in VS
is to register for COM interop and pay attention to the specific
requirements impossed by COM clients, please search MSDN for details on "COM
interop".

Note that this has nothing to do with "ActiveX controls", and as such has
nothing to do with the article Ollie pointed to.

Willy.
Nov 17 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1353
by: Paul D.Smith | last post by:
-- Please remove the "x-" if replying to sender.
4
1278
by: Micus | last post by:
Greetings, I would appreciate it if someone could recommend a few of the better C# and general .NET books for an intermediate C++ developer. I've searched the news groups and came up empty. My background has mainly focused on the Win32 API, ATL/COM and avoided MFC (if that info will help narrow down suggestions). TIA and Sorry if this has been asked/answered previously, M
3
5942
by: Micus | last post by:
I was wondering what the thought behind the 'new' keyword was in C# when applied to a function? For Example : public class A { ... public virtual void Func() { // impl_A} .... } public class B : A { ...
3
1682
by: Micus | last post by:
Greetings, I need to execute 2 applications from an application or batch file. The first app launched has the user enter a product key and the app's exit code will be 0 (failed) or 1 (succeeded). Based on the exit code of the first app, the second app will be run. My problems : Using a batch file to launch the applications produces an
0
8738
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8652
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9234
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9086
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8979
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7829
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5907
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3104
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2399
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.