hi this is stalin
hi mypage having dropdown list with autopostback="true",and this drop down binded with javascript function(i.e when i change the value in dropdown that javascript function shouldbe validated)
code for this is
ddl_freq.Attributes.Add("onChange", "javascript:return ValidateForm();");
now javascript function is validated correctly,when javascript function returns true (i.e value in the dropdown is correct) ,if javascript returns true , request will goto server but that is not performed here even though autopostback="true"
any body know solution to this please help me

1 answers
Hi,
try to add __doPostBack(); at the end of your ValidateForm() function.
Hope this may help you,
Thanks&Regards,
Anil.
answered 2 years ago by:
57
hi thanks for giving response,eventhough i didn't get solution for that
can u explain breifly please
answered 2 years ago by:
0
hi,
try like
function ValidateForm()
{
//your validation code
__doPostBack();
}
__doPostBack causes you to postback. And there you can catch the corresponsding event like,
protected void ddlCity_SelectedIndexChanged(object sender, EventArgs e)
{
}, where you can write your custom logic.
Hope this helps you,
Thanks&Regards,
Anil.
answered 2 years ago by:
57
This post was imported from csharpfriends, if you have a similiar question please ask it again.
All previous members have been migrated, hope you enjoy the new platform!