need onrowdatabound/ondatabound string parsing

Posted on 2007-03-27
Last Modified: 2012-05-05
i have a detailsview where I need a row modified ondatabound or on rowdatabound to remove the redundant names:

this is what it appears like on the screen:
employee names:    bob_smith

the employee_names field from the database comes in as a string with <br> tags in it:


I want to only have one instance of bob_smith. The data is quite complex so I'd rather attempt this on the detailsview inbound rather than play with the sql...
Question by:acdagirl
LVL 28

Expert Comment

ID: 18799260
Hello acdagirl,

Can't you use OnItemCreated event ?


Author Comment

ID: 18799631
sure, I guess so... how though? I'm more familiar with the rowdatabound... (p.s. I'm using .net 2.0)

Accepted Solution

fakir420 earned 500 total points
ID: 18800479
Add property


then is codebehind create the handler

protected void ItemBound(object sender, DataGridItemEventArgs e)

This is for a datagrid, but I imagine a DetailsView is much the same.  Just use 'DetailsViewEventArgs' instead of 'DataGridEventArgs' for the type.

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In .NET 2.0, Microsoft introduced the Web Site.  This was the default way to create a web Project in Visual Studio 2005.  In Visual Studio 2008, the Web Application has been restored as the default web Project in Visual Studio/.NET 3.x The Web Si…
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 …
This is a video that shows how the OnPage alerts system integrates into ConnectWise, how a trigger is set, how a page is sent via the trigger, and how the SENT, DELIVERED, READ & REPLIED receipts get entered into the internal tab of the ConnectWise …
Concerto provides fully managed cloud services and the expertise to provide an easy and reliable route to the cloud. Our best-in-class solutions help you address the toughest IT challenges, find new efficiencies and deliver the best application expe…

919 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

17 Experts available now in Live!

Get 1:1 Help Now