Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6769811
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T15:14:16+00:00 2026-05-26T15:14:16+00:00

I want to have the following HTML programmatically: <ul><li><a href=#></a></li></ul> I can add <li>

  • 0

I want to have the following HTML programmatically:

<ul><li><a href="#"></a></li></ul>

I can add <li> to <ul>. But <a> to <li> is not possible.

My code:

    BulletedList ul = new BulletedList();    
    ListItem li = new ListItem();    
    HyperLink hl = new HyperLink();
    ul.Items.Add(li);
    // li has no property Controls or Items
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T15:14:16+00:00Added an answer on May 26, 2026 at 3:14 pm

    From BulletedList, how to set link in ListItem, use the DisplayMode Property.

    <asp:BulletedList ID="BulletedList6" runat="Server" DisplayMode="HyperLink">
        <asp:ListItem Text="Los Angeles" Value="http://www.Los Angeles.aspx"></asp:ListItem>
        <asp:ListItem Text="Atlanta" Value="http://wwwAtlanta.aspx"></asp:ListItem>
        <asp:ListItem Text="San Francisco" Value="http://www.San Francisco.aspx"></asp:ListItem>
    </asp:BulletedList>
    

    Or in your code:

    BulletedList ul = new BulletedList();
    ul.DisplayMode = BulletedListDisplayMode.HyperLink;
    ListItem li = new ListItem();
    ul.Items.Add(li);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have following HTML code. writer input field is text filed. but I want
I have the following html generated through my PHP code. What I want to
i have following HTML code:- <table class=results> <tr> <td> <a href=..>link</a><span>2nd Mar 2011</span><br>XYZ Consultancy
I have the following HTML code in my ASP.NET application and I want to
I have the following HTML code: <td class=myclass width=1% align=right ><a href=javascript:goToNav(); id=top><img id=navup
I have the following html- <a href=http://address.com>John</a>: I really <b>love</b> <b>soccer</b>; I want to
I have following generrated HTML, and I want to add some CSS class to
I have the following HTML with Javascript: <A HREF=javascript:void(0)onclick=window.open('http://www.msn.com/','New Windows','height=380, width=300,location=no')>Hide Address Bar</a> It's
I have the following html content: <p>My name is <a href=way2project>way2project</a></p> Now I want
i have the following html , and i want to hide all lsHeader which

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.