I have a problem with what is DropDownListlosing SelectedValueafter PostBackon the server alone on the web farm. On other servers, everything works correctly.
All servers are on the same version of the code with the same service packs and all applicable updates. The code also works correctly when I start my local machine (but point to the production database).
I thought that ViewState might be a problem, but I confirmed that web.config, page aspxand code are the same for all machines.
Convert.ToInt32()I received an error while trying Input string was not in a correct format..
I added Trace.Writeto find out that the value DropDownListis nullonly on this particular server.
Code snippet
protected void Page_Load(object sender, System.EventArgs e)
{
if (!Page.IsPostBack)
{
LoadClientDropDown();
}
}
protected void LoadClientDropDown()
{
}
protected void btnSave_Click(object sender, System.EventArgs e)
{
int clientValue = Convert.ToInt32(ddlClients.SelectedValue);
}
What can I lose?
adam
source
share