Groups | Blog | Home
all groups > inetserver asp components > november 2003 >

inetserver asp components : What is the .NET equivilant of an ASP COM component?


Thomas H
11/26/2003 6:33:15 PM
Hello all; I've been searching for this answer for a long time now;
hopefully someone here can help me?

I wrote a web application a year and a half ago. It used Javascript/ASP,
and interfaced to a database server. I didn't use ADO at all. I wrote a
component in Visual C++ 6.0, which used the OLE DB 2.0 SDK for database
access. It was a single-apartment-thread'd component installed into a COM+
Application (start/programs/administrative tools/component services). The
App worked beautifully. Server load was minimial, even with a hundred or
more people on at the same time. Best program I ever wrote!

I'd love to do the same thing with .NET. Now is the perfect time for me to
re-code Everything into .NET.

But what's the equivilant of the Component Object Model in .NET? I want to
stick with Visual C++ for the component, and I'll be using Managed
Extensions. I plan on using ADO.NET because it seems that "direct" OLE DB
is dead; that's why they came up with ADO anyway. It was hard to dig up any
information on the OLE DB SDK when everything in the www talked about ADO!

Do I just write a class in VC++.NET? Should I use the pre-jit'ter on it for
best performance? What about threading... will ASP.NET handle it
automatically via the .NET framework? (I'll be using VS.NET 2003 with .NET
Framework 1.1)

Please, please, don't tell me about COM Interop, and how to use COM Interop,
and where to find information about COM Interop. That's all anyone can tell
me. I don't want to use COM Interop- sure, that's my backup plan if I run
out of time, but that's not my goal. I want to re-write EVERYTHING. I
don't want to stick with 1998 technology!

It seems like most people use ADO.NET from directly inside their ASP.NET
pages. I want to write a "component". But that can't be what it's called,
because on all my searches for "component .NET", I find information about
things like data grids or drop down boxes. So there's gotta be a new name.
What's the new name for a VS6 COM component?

I mean, there's gotta be a new name, right? I want to see -better- server
performance, not worse. And coding everything up inside ASP.NET/C# not only
seems like a security risk, but it seems like a performance barrier.

Or does Enterprise Development still rely on compiled components and COM
services?

Thanks a ton!!

-TH

PL
11/28/2003 11:10:31 AM
[quoted text, click to view]

You write a .NET assembly (.dll) in Visual C++.NET, C#, VB.NET and either
just put it into the bin dir on your web application (site) or add it to the GAC
(global assembly cache).

Done ! Import it on the pages and use it, no need for COM.

As for performance, I can't answer that since I haven't really digged into that yet
but I would assume it's good (great answer, I know) so just try it.

PL.

AddThis Social Bookmark Button