473,503 Members | 6,587 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Component programming

nht
Hi, i have a question. I want to create my own components in C#. But i
want to create non visual components like datasets,data adapters etc.
How can i do that? From which class i must inherit my component?
Nov 16 '05 #1
2 1456
A non-visual component should derive from Control and not from UserControl
You can take controls like DataAdapter and SqlConnection, write properties
and methods that you want to expose and add it to the toolbox of client
project.
The code for component can contain properties and methods as follows:

public DataTable OrdersTable
{
get { return dsOrders1.Orders; }
}

public DataTable OrderDetailsTable
{
get { return dsOrders1.Order_Details; }
}

public DataRowCollection GetOrders(string custId)
{
daOrders.SelectCommand.CommandText = "select * from Orders where
customerId = '" + custId + "'";
daOrders.Fill(dsOrders1, "Orders");
return dsOrders1.Orders.Rows;
}

Hope this helps.
Sameeksha
(MCAD.Net)

"nht" wrote:
Hi, i have a question. I want to create my own components in C#. But i
want to create non visual components like datasets,data adapters etc.
How can i do that? From which class i must inherit my component?

Nov 16 '05 #2
nht,

You would inherit from Component, or implement the IComponent interface.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"nht" <ni*****@hotmail.com> wrote in message
news:19**************************@posting.google.c om...
Hi, i have a question. I want to create my own components in C#. But i
want to create non visual components like datasets,data adapters etc.
How can i do that? From which class i must inherit my component?

Nov 16 '05 #3

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

Similar topics

1
1391
by: Jason Nix | last post by:
I have created an Active Server Component (ASC) as a bridge between ASP and my existing C++ DLLs that we use in our PC-based program. Our intent is to re-use as much code as possible. But, when I...
3
2583
by: Michael Crawford | last post by:
Hi, Where would one start for this type of application: I want to create an vb.net container application that has the gives the end user the ability to install and uninstall plugins or add-in...
2
290
by: mdk | last post by:
Hi all, I wonder if a COM component (eg ActiveX component) can be used on .NET platform? What is the difference between .NET component and COM/ActiveX component? What is the difference in...
2
1243
by: Bradley Grant | last post by:
I been trying to write a program to access a COM Component for a while now, with out much success so far. The following is part of the code of my program, and this is the message I get, can anyone...
0
954
by: Nijazi Halimaji | last post by:
Hi Newsgroup I have written a .NET Component, made the check on "register for COM interop" in Build options, create a strong name and registered the assembly in the GAC. Accessing this...
3
2206
by: Michel Smit | last post by:
I'm running into another problem with my component. I'm trying to use .NET remoting to avoid complex firewall issues. I have a webserver which is the client machine and a database server which...
122
7209
by: Edward Diener No Spam | last post by:
The definition of a component model I use below is a class which allows properties, methods, and events in a structured way which can be recognized, usually through some form of introspection...
2
5478
by: egress | last post by:
Forgive me for stupid questions for I am new to serial IO programming. I am developing an app that will need to communicate with a device via RS232 protocol using a standard 9 pin serial cable. ...
0
1088
by: fiona | last post by:
FOR IMMEDIATE RELEASE Catalyst releases Catalyst Internet Mail .NET V5.0 Message Delivery and Management .NET Component Yucca Valley, CA, - November 2007: Catalyst Development Corporation,...
0
7193
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,...
1
6975
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...
0
7449
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5562
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,...
1
4992
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4666
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...
0
3160
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1495
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 ...
1
728
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.