C# Ascx in VB.net Web App

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
 
J

Jeff Johnson

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.
 
L

Lau Lei Cheong

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)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,764
Messages
2,569,567
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top