Hi ran rajendra@patil55,
If you mean like validating a form or something here is something i would like to share, hope this helps.
in the head of your page:
<script type = "text/javascript">
function validate() {
var txt = document.getElementById("<%=Textbox1.ClientID%>").value;
if (txt == "") {
alert("Please enter your name in the textbox before proceeding.");
}
else {
window.location = "default.aspx";
}
}
</script>
and in the button:
<asp:button id="Button1" runat="server" text="Proceed" onclientclick="validate(); return false" xmlns:asp="#unknown" />
the return false after the function call prevents the postback.