[CLOSED] New Culture Resources

  1. #1

    [CLOSED] New Culture Resources

    Hi,

    In our MVC application, we need to add eu-ES culture and it looks like this culture is not supported by Ext.NET controls.

    Is there any way to add new text resources from an specific culture?

    Thanks.
    Last edited by Daniil; May 04, 2012 at 2:04 PM. Reason: [CLOSED]
  2. #2
    Hi,

    You could look at any JavaScript locale file to understand how it's implemented.
    <Ext.Net SVN root>\Ext.Net\Build\Ext.Net\extnet\locale\ext-lang-es.js

    You could take the locale above as a base for your one.

    As well, you can use the standard ASP.NET localization mechanism.
    http://forums.ext.net/showthread.php?11194
  3. #3
    Thanks Daniil.

    And once we build our own js (in our case f.e. we will need GridPanel texts) and set user culture via Threading, is any other step needed in order Ext.NET controls get the required resource file?

    Thanks again.
  4. #4
    Hi again,

    Where are GridPanel texts located? Because texts as "Page {0} of {1}" and "Displaying {0} - {1}" are not located at
    <Ext.Net SVN root>\Ext.Net\Build\Ext.Net\extnet\locale\ext-lang-es.js

    Thanks.
  5. #5
    Well, you need to add your JavaScript file on the page.
    <script type="text/javascript" src="resources/js/myEuEsLocale.js"></script>
    Or dynamically:
    protected void Page_Load(object sender, EventArgs e)
    {
        this.ResourceManager1.RegisterClientScriptInclude("myEuEsLocale", "resources/js/myEuEsLocale.js");
    }
  6. #6
    Quote Originally Posted by softmachine2011 View Post
    Where are GridPanel texts located? Because texts as "Page {0} of {1}" and "Displaying {0} - {1}" are not located at
    <Ext.Net SVN root>\Ext.Net\Build\Ext.Net\extnet\locale\ext-lang-es.js
    These properties are the PagingToolbar ones. See:
    if(Ext.PagingToolbar){
      Ext.apply(Ext.PagingToolbar.prototype, {
        beforePageText : "P\u00E1gina",
        afterPageText  : "de {0}",
        firstText      : "Primera p\u00E1gina",
        prevText       : "P\u00E1gina anterior",
        nextText       : "P\u00E1gina siguiente",
        lastText       : "Ăšltima p\u00E1gina",
        refreshText    : "Actualizar",
        displayMsg     : "Mostrando {0} - {1} de {2}",
        emptyMsg       : 'Sin datos para mostrar'
      });
    }
  7. #7
    Perfect.

    Thank you very much.

Similar Threads

  1. [CLOSED] Change culture of ext:datepicker
    By Jurke in forum 1.x Legacy Premium Help
    Replies: 15
    Last Post: Jan 28, 2013, 2:03 PM
  2. Culture name 'da-da' is not supported.
    By plykkegaard in forum Bugs
    Replies: 9
    Last Post: Jun 20, 2011, 6:52 AM
  3. Replies: 4
    Last Post: Apr 15, 2011, 3:53 PM
  4. [CLOSED] Calendar language culture
    By jsemple in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Dec 11, 2009, 7:31 AM
  5. [CLOSED] DateField culture issue
    By jsemple in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Sep 16, 2009, 1:59 PM

Posting Permissions