getting form input value on ajax loaded form using livequery

getting form input value on ajax loaded form using livequery

I have multiple forms that could be fetched using ajax and inserted into the current page.
I can successfully capture the submit click using
  1. $('#NewFormSubmitButton').livequery('click',function(){
      alert("testing submit button click");
  2.   return false; // prevent form submission works fine.
  3. });
However, I cannot get the loaded form's input values. I tried a variety of options that all look a bit like this...
 
  1. $('#NewFormSubmitButton').livequery('click',function(){
      alert("testing submit button click"); // gets to this bit
  2.   var FormsFieldValue=$('#InputFieldID').attr('value');
  3.   // or var FormsFieldValue=$('#InputFieldID').livequery('attr','value');
  4.   alert("\nAnd field value=" + FormsFieldValue); // never gets to this bit
  5.   return false; // does not prevent form submission because of code error ealier.
  6. });

    But just cannot figure out the correct script code.

    Did loads of googling, but nada.
    Just to clarify, the form in question is not loaded when the page loads, but when the user makes a selection (which determines which form).The environment is pretty comlex, hence the very basic snippets.
    Any help most appreciated.
    Thanks.
    Paul