How to use custom image as bullet style in BulletedList

BulletedList Bullet Style Custom Image
ASP.NET BulletedList web server control render a list of items in bulleted format in web browser. BulletedList BulletStyle property get or set the bullet style for BulletedList server control. BulletStyle enumeration specifies the bullet style we can apply to list items in bulletedlist. BulletStyle enumeration have many possible values such as Circle, CustomImage, Disc, LowerAlpha, LowerRoman, Numbered, Square etc.

CustomImage bullet style allow developers to provide their own image for the bullet. If we set the CustomImage bullet style, We must also set the BulletedList BulletImageUrl property to the URL of the custom image to use. BulletedList CustomImageUrl property get or set the path to an image to display for each bullet in a BulletedList server control.

The following c# example code demonstrate us how can we set a custom image as bullet style for a BulletedList control in asp.net.
BulletedListCustomImage.aspx

<%@ Page Language="C#" %>

<!DOCTYPE html>

<script runat="server">

</script>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>How to use custom image as bullet style in BulletedList</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <h2 style="color:Red">BulletedList: BulletStyle CustomImage</h2>
        <asp:BulletedList 
             ID="BulletedList1"
             runat="server"
             BackColor="LightGreen"
             ForeColor="DarkGreen"
             Width="300"
             BulletStyle="CustomImage"
             BulletImageUrl="~/Images/star.jpg"
             BorderWidth="2"
             BorderColor="SeaGreen"
             >
             <asp:ListItem>Jenny</asp:ListItem>
             <asp:ListItem>Jones</asp:ListItem>
             <asp:ListItem>MonaLisa</asp:ListItem>
             <asp:ListItem>Sweety</asp:ListItem>
             <asp:ListItem>Shila</asp:ListItem>
             <asp:ListItem>KakPakhi</asp:ListItem>
             <asp:ListItem>SowaChanPakhi</asp:ListItem>
        </asp:BulletedList>
    </div>
    </form>
</body>
</html>
More asp.net examples