c# Resource (resx) Inheritance
<p>I am using resources on my <em>asp.net</em> application and need to make the key/value pairs available on the client. I have been able to get them there for a particular <strong><em>resource file</em></strong> by using an HttpHandler, but the standard inheritances are not working with the code I am using.</p>

<hr>

<p>Base <em>PM.resx</em> file contains the following</p>

<pre><code>key: a value: AAAAAA
key: b value: BBBBBB
key: c value: CCCCCC
</code></pre>

<hr>

<p><em>PM.pt.resx</em> file contains the following</p>

<pre><code>key: a value: ptptpt
</code></pre>

<hr>

<p>When I have a culture of <code>pt</code> on my browser or coded, I expect to get the following returned since the <code>pt</code> file only has a single entry in it and the base file contains the rest of the key/value pairs.</p>

<pre><code>key: a value: ptptpt
key: b value: BBBBBB
key: c value: CCCCCC
</code></pre>

<p>But I am only getting the following.</p>

<pre><code>key: a value: ptptpt
</code></pre>

<hr>

<p>The c# code that I am using to generate the JavaScript is as follows.</p>

<pre><code>public void ProcessRequest(HttpContext context)
    {
        ResourceManager rm = new ResourceManager("Resources.PM", System.Reflection.Assembly.Load("App_GlobalResources"));
        Thread.CurrentThread.CurrentCulture = new CultureInfo("pt-BR");//for testing culture change
        //ResourceSet resourceSet = rm.GetResourceSet(CultureInfo.CurrentUICulture, true, true);
        ResourceSet resourceSet = rm.GetResourceSet(Thread.CurrentThread.CurrentCulture, true, true);

        string r = string.Empty;

        if (resourceSet != null)
        {
            foreach (DictionaryEntry entry in resourceSet)
            {
                string resourceKey = entry.Key.ToString();
                object resource = entry.Value.ToString();
                r += "\"" + entry.Key.ToString() + "\": \"" + entry.Value.ToString() + "\", ";
            }
        }

        r = "var q = {" + r + " culture: \"" + Thread.CurrentThread.CurrentCulture.ToString() + "\"};";
        r += "console.log(q);$.each(q, function(k, v){console.log(k + \": \" + v)});";
        context.Response.Write(r);
    }
</code></pre>

<p>How can I get the inheritance to work in the code?</p>
