Ajax button.

2 posts, 0 answers
  1. SD
    SD avatar
    62 posts
    Member since:
    Apr 2010

    Posted 06 Jul 2010 Link to this post

    Hi Guys,

    I have the following button:
    <input id="allocationConfirmationForm:confirmOK" type="button" value="OK"  
     
    onclick="A4J.AJAX.Submit('allocationConfirmationForm:contentRegion','allocationConfirmationForm',event,{'parameters':{ 
     
    'allocationConfirmationForm:confirmOK':'allocationConfirmationForm:confirmOK'}  
     
    ,'actionUrl':'/vtdWeb/spring/dashboard?execution=e1s2&javax.portlet.faces.DirectLink=true'} );return false;"  
     
    name="allocationConfirmationForm:confirmOK"/> 

    I have tried several approaches (While knowing that is an Ajax button) and it seems to be failing. 
    When I tried:
      Element e = Manager.ActiveBrowser.Find.ByName("allocationConfirmationForm:confirmOK"); 
    Manager.ActiveBrowser.Actions.Click(e); 

    I got: 
    The target Element object passed in for this action is null. Action aborted. Possible causes to this exception is the 
    element not present in the page markup and the Find.Byxx returning null.
    Parameter name: TargetElement

    Have no issues with other buttons..(Inc Ajax buttons)What is wrong here ?
    Ta, 
    SD.

  2. SD
    SD avatar
    62 posts
    Member since:
    Apr 2010

    Posted 06 Jul 2010 Link to this post

    Sorry, my mistake...
    I guess it was not a very good idea to have executionDelay = 0....
Back to Top