Question

I know that if I created a custom control, say MyLabel in App_Code ..

namespace MyNamespace 
{
  public class MyLabel : Label { .. }
}

To access this control in my page, I would use this directive ..

<%@ Register tagPrefix="foo" Namespace="MyNamespace" %>

If I did not provide a namespace (MyNamespace), how do I write the Register directive?

Thanks so much.

Was it helpful?

Solution

<%@ Register tagPrefix="foo" %>

(you might need a tagName value also.)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top