Solved

How to dynamically add a custom row to a DetailsView

Posted on 2009-05-12
3
620 Views
Last Modified: 2013-11-08
Hi,

I want to add a custom row to a DetailsView from the code behind.

Please help!
0
Comment
Question by:robaherne
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 29

Expert Comment

by:chilternPC
ID: 24365450
ok.
without seeing what you have already I would use a few tests with IF statemetns to add in the custom row for writing to the clients screen
0
 

Author Comment

by:robaherne
ID: 24365496
This is what I have so far...

// Create new Template
TemplateField jobdate = new TemplateField();

// Set the fields header
 jobdate.HeaderText = "Job Time";

//Now I want to set the value of the field but I don't know how!
//Something like jobdate.FieldText = "16:30"; would be nice but it doesn't exist.

// And finally Add the field to the DetailsView
grid_JobTable.Fields.Add(jobdate);
0
 

Accepted Solution

by:
robaherne earned 0 total points
ID: 24366072
Nevermind... I found a work around.

I added a column to the datatable that was to bind with the details view, entered a custom value into that field and then created a standard databound field to pick up hte value.

Thanks anyways
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

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

Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

726 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