Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Interop / January 2004

Tip: Looking for answers? Try searching our database.

How to register .NET component to use with COM clients

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Prasad - 02 Jan 2004 13:16 GMT
Hi:

I have VB.NET component, which has methods to encrypt and decrypt the
database password.  The purpose for this is, we can't place database
password in plain text in .config file.  So we need to encrypt it and place
it in .config file, and while connecting to database we need to decrypt it.
So all it works fine, when we call this component in VB.NET.  Here the
problem is, while installing the application (in deployment environment),
installshield script will write database related user id and password in
.config file.  So installshield script has to use the VB.NET component.  I
created a type library for VB.NET component, using "tlbexp" tool.  After
this, i am installing type library (.tlb) using "regsvr32" tool (or by
selecting self registration option in installshield) and it displays the
following error.

EncryptDecrypt.tlb is not an executable file and no registration helper is
registered for this file type.

What might be the problem.  I can't use "RegAsm" tool, because this is a
.NET tool.  Please help.

- Prasad.
Christian Fröschlin - 02 Jan 2004 13:42 GMT
> What might be the problem.  I can't use "RegAsm" tool, because this is a
> .NET tool.

Since you want to use a .NET component, you also need the
.NET Framework on the target system. If this is not available,
you need to install it. Hence, you should be able to use regasm.
Prasad - 03 Jan 2004 05:47 GMT
Hi Christian:

Thanks for your reply.

.NET Framework will be installed, when the application is installed.  This
is done using installshield.  Regasm is a tool, which can be used in
development environment.  Why i want to use "regsvr32" to install the .NET
component (ofcourse after creating type library using tlbexp tool) is, when
we are registering the .tlb file (type library file of .NET component) using
installshield, it's giving the same error when i am registering using
regsvr32.  I thought if we install using regsvr32 tool, we can install using
installshield also.

Thanks.

- Prasad.

> > What might be the problem.  I can't use "RegAsm" tool, because this is a
> > .NET tool.
>
> Since you want to use a .NET component, you also need the
> .NET Framework on the target system. If this is not available,
> you need to install it. Hence, you should be able to use regasm.
Christian Fröschlin - 05 Jan 2004 08:48 GMT
> is done using installshield.  Regasm is a tool, which can be used in
> development environment.  Why i want to use "regsvr32" to install the .NET
> component (ofcourse after creating type library using tlbexp tool) is, when
> we are registering the .tlb file (type library file of .NET component) using
> installshield, it's giving the same error when i am registering using
> regsvr32.

I don't think regsvr32 can register tlb files. You can
try to use regtlib instead. Besides, I would expect that
an InstallShield script can execute any command you wish.
Phil Wilson - 08 Jan 2004 01:21 GMT
It depends exactly what InstallShield product you're using, but the Developer
editions from 8.0 onwards will do all this stuff almost automatically.  For
example, on the class library component properties in IS Developer you just
check "..NET Interop" and that causes all the registration goo to be built into
the resulting MSI file. .NET documentation describes utilities like regasm.
installutil, gacutil despite the fact that a Windows Installer setup just do all
that stuff without those utilities, and InstallShield Developer is one of the
products that can build them.
Signature

Phil Wilson [MVP Windows Installer]
----

> Hi Christian:
>
[quoted text clipped - 19 lines]
> > .NET Framework on the target system. If this is not available,
> > you need to install it. Hence, you should be able to use regasm.
Ian Campbell - 08 Jan 2004 20:00 GMT
Anyone know where I can find good example projects
for creating setup/depolyment programs (msi's) with visual studio 2003
is it even possible? or should i fork out for installsheild?

> It depends exactly what InstallShield product you're using, but the Developer
> editions from 8.0 onwards will do all this stuff almost automatically.  For
[quoted text clipped - 27 lines]
> > > .NET Framework on the target system. If this is not available,
> > > you need to install it. Hence, you should be able to use regasm.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.