Returned value from first Ajax call is not shown in the second ajax call

Hi,

I am new to JQuery and Ajax

I am trying to use the value returned from the Ajax call to the another Ajax call..

like

          $.ajax({
	 type: "POST",
	 url: "http://localhost/FormBuilder/index.php/forms/saveForm/",
               async: false,
		 data: "formname="+formname+"&status="+status,
		 success: function(msg){
		 //alert( "Data Saved: " + msg);                         

                            getformid=msg; 
                            }//success
		 });//ajax 

      $("#fb_contentarea_col1down21 div").each(function() { 
       alert("Form id "+getformid);//alerts me the Formid returned from the Cakephp controller side
		var checked="false";	 
		var id=$(this).attr("id");
		var fsize=$("#input"+id+"").width();
		var ftype=$("#input"+id+"").attr('data-attr');
		var finstr=$("#instr"+id+"").text();
                    var fname=$("#label"+id+"").clone().html().replace(/ span.req").length > 0)
						{

						 checked="true";

						}


			$.ajax({
			type: "POST",  
			 async: false,
			 url: "http://localhost/FormBuilder/index.php/forms/saveField",

                             data: "sequence_no="+id+"&name="+fname+"&type="+ftype+"&size="+fsize+"&instr="+finstr+"&formid="+getformid+"&required="+checked,
                              success: function(msg){
			//alert( "Data Saved: " + msg);
			}//success
		 });//ajax
		});//DIV

The First Ajax call returns the Formid and even alerts it correctly in the Div ,But the returned value in getformid is not reflected in the second ajax call .
Please sugggest me..
May be the question is somewhat a repitation but i didnt got the solution, please help me.

Edit : Resolved the error. The cause is not in my Ajax calls at all its in my Cakephp controller where i return only my FOrm id and not the Form instance. i have changed and got the answer.THanks for every one who helped.