Hi mahesh213,
Refer below sample.
HTML
<asp:Label ID="lblMesssage" runat="server" />
Code
C#
protected void Page_Load(object sender, EventArgs e)
{
List<string> messages = new List<string>();
messages.Add("Sample Message1");
messages.Add("Sample Message2");
string formattedMessage = "<ul><li>" + string.Join("</li><li>", messages)+ "</li></ul>";
lblMesssage.Text = formattedMessage;
formattedMessage = "•" + string.Join("\\n•", messages);
ClientScript.RegisterStartupScript(this.GetType(), "alert", "alert('" + formattedMessage + "');", true);
}
VB.Net
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
Dim messages As List(Of String) = New List(Of String)()
messages.Add("Sample Message1")
messages.Add("Sample Message2")
Dim formattedMessage As String = "<ul><li>" & String.Join("</li><li>", messages) & "</li></ul>"
lblMesssage.Text = formattedMessage
formattedMessage = "•" & String.Join("\n•", messages)
ClientScript.RegisterStartupScript(Me.GetType(), "alert", "alert('" & formattedMessage & "');", True)
End Sub
Screenshot