How do I access public properties when sharing webforms codebehind for user control
<p>I am trying to make an ascx control that can be templated by our front-end developers by just making a new .ascx and pointing to that specific .ascx in that instance.  However, I am having issues with accessing properties in shared code-behind scenarios.</p>

<p>I have the following code behind that's shared</p>

<pre><code>public partial class TemplateCodeBehind : TemplateControlBase
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    // Ascx Available properties
    public string GetOption1Value { get { return Option1; } }
    public string GetOption2Value { get { return Option2; } }
    public string GetOption3Value { get { return Option3; } }
    public string GetOption4Value { get { return Option4; } }
}
</code></pre>

<p>Note that those options that are returned are public properties of the <code>TemplateControlBase</code> class.  In my Templates subfolder I have the following ascx</p>

<pre><code>&lt;%@ Control Language="C#" AutoEventWireup="false" CodeBehind="../TemplateCodeBehind.ascx.cs" Inherits="MyNamespace.JqueryTemplates.TemplateCodeBehind" %&gt;
&lt;%@ Import Namespace="MyNamespace.JqueryTemplates" %&gt;

&lt;div&gt;
     Option1: &lt;%= GetOption1 %&gt;

&lt;/div&gt;
</code></pre>

<p>This compiles fine, but when I try to load my test ascx I get the following error</p>

<blockquote>
  <p>An error has occurred. DotNetNuke.Services.Exceptions.PageLoadException: c:\Projects\DNN-Dev\Website\DesktopModules\Module.JqueryTemplates\Templates\Test.ascx(5): error CS0103: The name 'GetOption1' does not exist in the current context </p>
</blockquote>

<p>I have tried changing <code>&lt;%=</code> to <code>&lt;%#</code> and calling <code>Page.Databind()</code> but nothing seems to work.</p>

<p>Any ideas on how I can accomplish this?</p>
