C# Ascx in VB.net Web App

  • Thread starter Thread starter George Durzi
  • Start date Start date
G

George Durzi

So I'm working on a VB.NET web application, and I'd like to build a user
control in C# and use it within my VB .NET web app.

What kind of project do I need to create that user control in. Are they any
examples of how I would "reference" that user control in my project?

Thank You
 
So I'm working on a VB.NET web application, and I'd like to build a user
control in C# and use it within my VB .NET web app.

What kind of project do I need to create that user control in.

My guess would be a Web Control library.
Are they any examples of how I would "reference" that user control in my
project?

Probably like you'd reference any other DLL. Give it a try and see.
 
My guess would be to move all the contents of .ascx.cs to your .ascx file,
surrounded with <script runat=server> tag so the server will try to compile
it at runtime, maybe without trying to compile it to the DLL file...(not
very sure it'll work or not)
 
Back
Top