Hi Rohit,
While you can't mix C# and VB within the same project, you can mix them in
the same assembly and you don't need to use a separate class library. To do
this, you need to compile your C# class as a .NetModule, then add that
module when you compile your VB app. This needs to be compiled from the
command-line, as it isn't directly supported within Visual Studio. The
command lines could be something like:
csc /t:module /out:CSharp.NetModule CSharp.cs
vb /t:exe /out:VbTest.Exe /addmodule:CSharp.NetModule VbTest.vb
NetModules are also quite cool in that they allow you to create a plug-in
architecture for your apps.
HTH,
Mark
--
Author of "Comprehensive VB .NET Debugging"
http://www.apress.com/book/bookDisplay.html?bID=128
"Rohit Sharma" <lt*************@hotmail.com> wrote in message
news:es**************@TK2MSFTNGP11.phx.gbl...
Hi All,
I have a VB .NET application. I want to use one class written in CS. Can I
include the CS file and use the class in my VB app? I have tried it but I
cant seem to instantiate the class....
Cheers
Rohit