AutoCompleteText box is not retaining its value on post back

Hi,

Im using syncfusion version 9.4.0.62 and using autocompeltetextbox. The problem was it was not retainig the value supplied as input. so AutoCompleteTextBox1.Text property is having empty value always. Below is the code.

Width="200px" OnTextChanged="autoCompTextProjectName_TextChanged" OnProvideChoiceListOnCallback="autoCompTextProjectName_ProvideChoiceListOnCallback"
DDBackColor="MintCream" DDcssClass="SelectionClass" Visible="false">



protected void autoCompTextProjectName_ProvideChoiceListOnCallback(object sender, Syncfusion.Web.UI.WebControls.Tools.ACUserChoiceListEventArgs e)
{
e.ChoiceList = ProjectNames; //This is an arraylist
}

- Vijay



3 Replies

VR Varalakshmi R.S Syncfusion Team February 3, 2012 06:22 AM UTC

Hi Vijay,

Thanks for contacting Syncfusion forums.

We have checked the code provided by you and found that “AutoPostBack” property was not enabled to retrieve the updated text from AutoCompleteTextBox. Kindly enable this property and the text. Please refer the code given below to achieve this,


[ASPX]
Width="200px" OnProvideChoiceListOnCallback="AutoCompleteTextBox1_ProvideChoiceListOnCallback1" AutoPostBack="true"
DDBackColor="MintCream" DDcssClass="SelectionClass" >



We have also prepared a sample to depict this behavior and the sample can be downloaded from the following link,
autocomplete142004666.zip

Kindly try the sample and let us know if it helps.

Regards,
Varalakshmi





VJ Vijay Jayaraj February 3, 2012 09:38 AM UTC

Hello Varalakshmi,

I tried that already by setting the Autopostback = true, and my autocompletion text box was there inside an update panel. So post back is happening for any text change in the control but that text what the user is entering is not available in the post back of this cotrol or may be other control's post back.


Thanks.

- Vijay





VR Varalakshmi R.S Syncfusion Team February 3, 2012 12:15 PM UTC

Hi Vijay,

Thanks for the update.

The selected text have not been updated in the AutoCompleteTextBox due to partial post back when this is included inside an update panel. You can check the same scenario with asp textbox where as the value have not been updated here also.

Kindly check the details and let us know if you would require further assistance on this.

Regards,
Varalakshmi



Loader.
Up arrow icon