Hi nauna,
Refer below code.
HTML
<asp:Panel ID="Panel1" runat="server" Height="100px" ScrollBars="Vertical" style="background-color:antiquewhite;">
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
Testing <br />
</asp:Panel>
<br />
<asp:Button Text="Scroll to Bottom" runat="server" OnClick="OnScroll" />
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
<script type="text/javascript">
function ScrollPanelBottom() {
var text = $('[id*=Panel1]');
text.scrollTop(text[0].scrollHeight);
};
</script>
Code
C#
protected void OnScroll(object sender, EventArgs e)
{
string script = "window.onload = function() { ScrollPanelBottom(); };";
ClientScript.RegisterStartupScript(this.GetType(), "message", script, true);
}
VB.Net
Protected Sub OnScroll(sender As Object, e As EventArgs)
Dim script As String = "window.onload = function() { ScrollPanelBottom(); };"
ClientScript.RegisterStartupScript(Me.GetType(), "message", script, True)
End Sub
Screenshot