tags:

views:

42

answers:

1

This is weird. I declare a web user control on a asp.net web page like so

print("<%@ Register Src="~/Controls/blah.ascx" TagName="blahCtrl" TagPrefix="cc" %>");

I don't have problem with it until today in the code behind where it give me name blah is not declared error. does anyone know what cause this?

+2  A: 

Try registering it on the .aspx source page not the .aspx.cs page.

Matt