Solved

Nested Repeaters with C#

Posted on 2004-08-05
2
195 Views
Last Modified: 2008-03-17
I have an object that looks like this :

int frequency
string term
string eventtitle
string presenter
string phone
string email
DateTime begintime
DateTime endtime
.....etc.....

Now on my display page I have an array of these objects named events.

I would like the page to display as follows:

Monthly (frequency = 2)
-----------------------------------------------------
           Fall (term)
           ~~~~~~~~~~~~~~~~~~~~~~~~~
             Event 1 (eventtitle)      Joe Smith (presenter)     ...etc.....
             Event 3 (eventtitle)      John Jacobs(presenter)     ...etc.....
             Event 4 (eventtitle)      Mary Black (presenter)     ...etc.....

           Winter (term)
           ~~~~~~~~~~~~~~~~~~~~~~~~~
             Event 2 (eventtitle)      Bob Brown (presenter)     ...etc.....
             Event 6 (eventtitle)      Suzy Sanchez(presenter)     ...etc.....

Weekly (frequency = 1)
-----------------------------------------------------
           Summer(term)
           ~~~~~~~~~~~~~~~~~~~~~~~~~
             Event 10 (eventtitle)      George Jefferson (presenter)     ...etc.....

           Winter (term)
           ~~~~~~~~~~~~~~~~~~~~~~~~~
             Event 21 (eventtitle)     Jim Ploney (presenter)     ...etc.....
             Event 67 (eventtitle)     Henry Howards (presenter)     ...etc.....


So basically grouped first on frequency,
then within frequency grouped on term,
then within term ordered by event title


I can change the array of objects to a collection or some other structure, but cannot access the database tables directly (using a N-tier structure for our project) becaues we are isolating the presentation layer from the data and business layers.

How do I go about binding this data to a repeater or datalist in order to have the heirarchical display mentioned above.

Thanks!!

 
0
Comment
Question by:mrichmon
2 Comments
 
LVL 35

Author Comment

by:mrichmon
ID: 11887521
OKay apparently no one here knows the answer...

I came up with a work around which is to write a function in the presentation layer that manually calculates whether it is a new group or not.

A very clumsy/clunky work-around, but it works
0
 

Accepted Solution

by:
CetusMOD earned 0 total points
ID: 11890170
Closed, 500 points refunded.
CetusMOD
Community Support Moderator
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

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,…
Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

744 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

13 Experts available now in Live!

Get 1:1 Help Now