#{Hidden1}.getValue() failing

  1. #1

    #{Hidden1}.getValue() failing

    *Hi All,

    I am excited about Coolite. *I need to show a prototype to my boss to get his blessing on the toolset. *What I am trying to do is real basic ... and its within a UserControl (not that it makes a difference on this one). *


    There is a hidden field in that user control that I am using to hold the line item number. When any field fires off it reports back to the AJAX method with its control id, value, and needs to return the Hidden1 value. *


    	<ExtraParams>*                                        
    		<ext:Parameter Name="ctlid"     Value="#{Mon}" />*                                        
    		<ext:Parameter Name="ctlvalue"  Value="#{Mon}.getValue()"   Mode="Raw" />*                                        
    		<ext:Parameter Name="guid"      Value="#{Hidden1}" />
    		// <-- Good, returns 'ctl03_Hidden1'
    	</ExtraParams>
    
    
    	<ext:Parameter Name="guid" Value="#{Hidden1}" Mode="Raw"/>*	// <-- Nope, error undefined as i can tell
    
    
    
    	<ext:Parameter Name="guid" Value="#{Hidden1}.getValue()" Mode="Raw"/>*	// <-- Nope, THIS IS WHAT I NEED
    *


    As you see, entering 'Raw' mode causes this to fail. *Any help is much appreciated!!!
  2. #2

    RE: #{Hidden1}.getValue() failing

    *Ok. *Very next thing i try ... i get this to work. *New it was too simple. *Anyway here is what works. *The reason it was failing was that i was trying to invoke a function when the call needed to be to a property. *I think the error codes reported were strange. *I was also thrown off that a Mode='Raw' call to just {Hidden1} failed. *That got me going down the wrong track .. like thinking the item coudnt be found. *Didn't help that 'too much recursion' error message was thrown by javascript.

    // -- this works now!!! --
    	<ExtraParams>
    		<ext:Parameter Name="ctlid"     Value="#{Mon}" />
    		<ext:Parameter Name="ctlvalue"  Value="#{Mon}.getValue()"   Mode="Raw" />
    		<ext:Parameter Name="guid"      Value="#{Hidden1}.value" Mode="Raw" />*                                    
    	</ExtraParams>
  3. #3

    RE: #{Hidden1}.getValue() failing

    Hi Juls,

    Is "Hidden1" an <ext:Hidden> control? If yes, then #{Hidden1}.getValue() should be correct. I'll run a test to confirm.


    Geoffrey McGill
    Founder
  4. #4

    RE: #{Hidden1}.getValue() failing

    Hi Juls,

    The following should work.


    Example


    <ext:Parameter Name="guid" Value="#{Hidden1}.getValue()" Mode="Raw"/>

    Another option would be the following.


    Example


    <ext:Parameter Name="guid" Value="#{Hidden1}.el.dom.value" Mode="Raw"/>


    Hope this helps.


    Geoffrey McGill
    Founder
  5. #5

    RE: #{Hidden1}.getValue() failing

    *Thanks for the fast reply. *

    Going to try out your methods. *As well i looked at the docs and realized that 'value' is a property on the Ext:Hidden object while getValue() would have been a call to a function. *


    Guess I should try to RTFM more. *Thanks again! *Coolite is awesome! *


    BTW. *Is there a place for us to post code snippets? *It would be a helpful augmentation to the docs.

Similar Threads

  1. [CLOSED] iframe onFocus failing w/Chrome & Firefox
    By randy85253 in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Apr 12, 2012, 8:08 AM
  2. Replies: 5
    Last Post: Jul 15, 2011, 9:25 AM
  3. Gridpanel update/delete failing
    By rajesh.chd in forum 1.x Help
    Replies: 8
    Last Post: Dec 07, 2010, 12:08 PM
  4. FindControl for dynamic textfield failing
    By venuc in forum 1.x Help
    Replies: 8
    Last Post: Feb 03, 2010, 11:40 AM
  5. [CLOSED] Failing Ajax Event (using Failure property)
    By gokcemutlu in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Apr 07, 2009, 11:38 AM

Posting Permissions