Solved

bulleted list help

Posted on 2006-11-17
2
335 Views
Last Modified: 2012-06-21
I have a bulleted list control on my page and have successfully binded data to the list:

if (!Page.IsPostBack)
{

BulletedList1.DataSource = EmploymentOpportunityDAO.GetList();
BulletedList1.DataValueField = "ID";
BulletedList1.DataTextField = "title";
BulletedList1.DataBind();
}

What I'd like to do is set the DataTextField to a link and pass the DataValueField in a QueryString to my details page, EmploymentDetails.aspx, so I can display all the data.

I'm trying to do something like the following:
"<li><a href='EmploymentDetails.aspx?id=" + emp.ID + "'>" + emp.title.ToUpper() + "</a></li>"

I just don't know how to do this with a bulleted list control?


Also how can I convert the DataTextField to uppercase?  I was trying to use ToUpper(), but I'm not coding it correctly.

Thanks for any help.
0
Comment
Question by:-Dman100-
2 Comments
 
LVL 13

Accepted Solution

by:
jeebukarthikeyan earned 500 total points
ID: 17970763
Hi ,
      <asp:bulletedlist id="BulletedList1" runat="server"
        displaymode="HyperLink"
        datasourceid="Datasetdatasource1"
        datatextfield="Name"                          //give the text here
        datavaluefield="Url" />                       //give the url here

b u d d h a
0
 

Author Comment

by:-Dman100-
ID: 17971214
Thanks budda,

How do I set the datavaluefield as a querystring?

I'm trying:

DataValueField="employmentdetails.aspx?id= + employment_opportunity_id"

that doesn't work.  What is the correct syntax?

Thanks for your help.
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

AJAX ModalPopupExtender has a required property "TargetControlID" which may seem to be very confusing to new users. It means the server control that will be extended by the ModalPopup, for instance, if when you click a button, a ModalPopup displays,…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now