[CLOSED] TextField.getValue()

  1. #1

    [CLOSED] TextField.getValue()

    Hi

    I has a store in my GridPanel bind with a WebService, and I pass a parameter 'filter' to my WebService method...

    <Parameters>
       <ext:StoreParameter Name="filter" Value="getDividasFilter()" Mode="Raw" />
    </Parameters>
    I store the code for my company in a hidden field to be passed in filter StoreParameter
    <ext:Hidden runat="server" ID="txtIDEmpresa" />
    However, in my script function, an error occurs saying that the getValue() is not a txtIDEmpresa method...
    follows the script ... What am I doing wrong?

    <script type="text/javascript" language="javascript">
    
        function getDividasFilter() {
           if (txtIDEmpresa.getValue() != "") {
               sFilter = "COB_DIVIDAS.IDEmpresa=" + txtIDEmpresa.getValue() + " AND IDSituacaoCobranca>-1 AND SuperaWeb=1";
           }
           return sFilter;
    }
    Thanks for any help.
    Last edited by Daniil; Jan 20, 2012 at 7:48 PM. Reason: [CLOSED]
  2. #2
    Hi,

    In v2, there is the default namespace 'App', any widget will share own client id in that namespace.

    You can use:

    Example 1
    App.txtIDEmpresa
    As well, you can set empty or your custom Namespace in ResourceManager.

    Also you can use the #{} syntax.

    Example 2
    <ext:XScript runat="server">
        <script type="text/javascript">
            var showValue = function () {
                #{TextField1}.getValue();
            };
        </script>
    </ext:XScript>
    An <ext:XScript> control is not required when you use #{} in markup.

    We will add a respective CHANGELOG item.
    Last edited by Daniil; Jan 23, 2012 at 9:06 AM.
  3. #3
    Hi Vladimir...

    Ok, Thanks... your suggestion works fine.
  4. #4
    Quote Originally Posted by Vladimir View Post
    We will add a respective CHANGELOG item.
    Item #90:
    https://examples2.ext.net/#/Getting_...nts/CHANGELOG/

Similar Threads

  1. [CLOSED] ComboBox getValue returns text instead of value
    By marco.morreale in forum 2.x Legacy Premium Help
    Replies: 9
    Last Post: Jun 19, 2012, 7:22 AM
  2. [CLOSED] Combobox getValue
    By jthompson in forum 1.x Legacy Premium Help
    Replies: 25
    Last Post: Jun 15, 2012, 11:14 AM
  3. Format datefield getValue
    By Tbaseflug in forum 1.x Help
    Replies: 1
    Last Post: Oct 21, 2011, 1:23 AM
  4. [CLOSED] [1.0] combobox getValue on select event
    By PoloTheMonk in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Feb 10, 2010, 7:32 AM
  5. #{Hidden1}.getValue() failing
    By Juls in forum 1.x Help
    Replies: 4
    Last Post: Mar 20, 2009, 3:40 PM

Posting Permissions