Hi, I want to call JQuery and VB function on the same time in one button, but I have a problem when calling them, the JQuery didn't work.
I have this button:
<asp:Button ID="Display" runat="server" Text="Tampilkan" />
while I have VB function on the back it:
Protected Sub Display_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Display.Click
// my code
End Sub
and this JQuery script for scrolling down to the next div:
<script type="text/javascript">
$(function(){
$("#<%=Display.ClientID %>").click(function(){
//scroll to the second div
$('html,body').animate({
scrollTop: $(".secondrow").offset().top },
'slow');
});
});
</script>
The problem is while the VB function and the JQuery are firing on the same time, the JQuery which should go down, it went back to the first place and the VB function is work.
Thank you for your help