PDA

View Full Version : Dynamically fill a form with asp



Gamer
26 Apr 2011, 10:48 AM
I am pulling from my table using asp


"SELECT u_fName, u_address, u_phone FROM dbo.Customer WHERE u_email = '"&email&"'"


Then I want to fill textfields with the data ie address field, after getting the data in the asp page how do I get it to show up in the fields?



{
xtype: 'textfield',
draggable: true,
id:'nameField',
placeHolder:'Bob'
}

do I need a setValue? and how do I go about putting the values into the field from this:



Ext.Ajax.request({
url: 'src/demos/autopop.asp',
method: 'post',
scope: this,
failure : function(response){
Ext.Msg.alert('Autopopulate Error', 'Please Login', Ext.emptyFn);
},
success: function(response, opts) {

Ext.Msg.alert("V-Card Setup Success",'Enjoy Your V-Card Experience', Ext.emptyFn);
Ext.getCmp('nameField').setValue();
}
});