473,666 Members | 1,991 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

NEWB Q: Do I use a repeater?

I created a web site in ASP that is heavily data driven. On the home page,
http://iheartmypond.com/. The list of categories is gathered from the
database. I grab the distinct top level categories, and show them with the
first five level 1 sub categories. I then loop through the list and using
response.write, I build a table that formats the category lists as shown on
the home page.

I am trying to replicate this in ASPX and having all kinds of problems. I
have been told I cannot use response write to do this, and should use
response.write in ASPX at all. It has been suggested I use a nested repeater
to create this format, but I have not been able to create anything more then
this:

Category
Sub 1
Nov 18 '05 #1
2 1183

"Tampa .NET Koder" <Ta***********@ discussions.mic rosoft.com> wrote in
message news:BD******** *************** ***********@mic rosoft.com...
You can probably go and look at the datalist. If the repeater isn't giving

you what you want. Or, you can use string concantenation to add the HTML
text to a string and then output this on the aspx page in a literal control
or a label. I will see if anyone has any other suggestions
<snip>

I have not been able to get the datalist nor the repeater to do what I want,
but admitedly I am a newb to .NET, so it is probably me. This is why I am
posting. I am hoping someone can point me towards an example. The idea of
the label or text box may work if I can embed some more complex formating.
I'll try that, thanks.

BV.
Nov 18 '05 #2
Or you can get the data as an xml file using getxml from the dataset, create an xslt file for the style sheet. Create just a label on the aspx Then use xpathdocument and xmltransform objects to feed this into the label.

Dynamic Help is gives a great deal more on Repeater controls etc

--
Ibrahim

"Tampa .NET Koder" wrote:
You can probably go and look at the datalist. If the repeater isn't giving you what you want. Or, you can use string concantenation to add the HTML text to a string and then output this on the aspx page in a literal control or a label. I will see if anyone has any other suggestions

"Benign Vanilla" wrote:
I created a web site in ASP that is heavily data driven. On the home page,
http://iheartmypond.com/. The list of categories is gathered from the
database. I grab the distinct top level categories, and show them with the
first five level 1 sub categories. I then loop through the list and using
response.write, I build a table that formats the category lists as shown on
the home page.

I am trying to replicate this in ASPX and having all kinds of problems. I
have been told I cannot use response write to do this, and should use
response.write in ASPX at all. It has been suggested I use a nested repeater
to create this format, but I have not been able to create anything more then
this:

Category
Sub 1
.
.
.

Category 2
Sub 1
.
.
.

Category 3
Sub 1
.
.
.

Can anyone offer some advice?

BV.

Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
5397
by: Ed Allan | last post by:
http://ejaconsulting.com/nestedrepeater/NestedRepeater.txt >-----Original Message----- >Doh! The HTML has all been rendered . . . > >Right click on this link and select 'Save target as ..' >to get the code in a text file. > >Thanks - Ed >
8
4274
by: Invalidlastname | last post by:
Hi, We are developing an asp.net application, and we dynamically created certain literal controls to represent some read-only text for certain editable controls. However, recently we found an issue which is related to the repeater. In the code shown below, if I call Repeater1.Controls.Count in the OnInit (the code fragment was highlighted in yellow) , the viewstate for the repeater will be lost during the postback. You can re-produce this...
0
1785
by: Amir | last post by:
Hi every one This is the problem: I have a UserControl that contains a Repeater and a few LinkButton. The Repeater generate some linkButton. I use this control for implementing paging solution for another repeater in page. (So I have a repeater and a Usercontrol that contains repeater)
3
4415
by: sorCrer | last post by:
Hi All, Posted after extensive searching! I have a nested repeater control as follows: (Simplified ;-)) <table> <asp:repeater id=parent onItemDataBound=createChild> <tr><td>Level 1</td></tr> <asp:repeater id=child>
8
2907
by: I am Sam | last post by:
Hi everyone, This problem is making me old. I don't want to get any older. I have a multi-nested repeater control as follows: <asp:Repeater ID="clubRep1" Runat="server"> <HeaderTemplate><table> </HeaderTemplate> <ItemTemplate>
1
5431
by: olduncleamos | last post by:
Hello all, I am experimenting with the repeater control and ran into something that I wasn't expecting. I would appreciate if the experts can confirm or correct my understanding. Here is a fragment of a very simple page that I wrote that will drill down into the displayed item. The result is to be display on the same page so that the user can keep on drilling down:
2
1913
by: GD | last post by:
I'd like to use a Repeater to display data coming back from a cross-tab report. Because it's a cross-tab, I generally don't know how many columns are coming back. They do follow a certain format: e.g. CompanyName, c1, c2, c3, etc .. The current format of my repeater is: <table> <asp:Repeater ID="rptCompanies" Runat="server">
8
3019
by: fernandezr | last post by:
I would like to use a user control as a template inside a repeater. Some of the fields in the control should be hidden depending on whether or not there is data. I'm still a ASP .Net newbie so the way I'm going about doing this might be a little off. I'd appreciate some help. Below is the code I have thus far but I'm not sure how to reference the user control within the foreach loop. <asp:Panel ID="pnlRosterProfile" runat="Server" />
0
4090
by: uncensored | last post by:
Hello everyone, I'm fairly new at .Net and I have a repeater inside a repeater problem. I will attach my code to this message but basically what I am able to tell when I run my page it tells me that my second repeater has the following error, System.NullReferenceException: Object reference not set to an instance of an object. When I put a watch on I can see my second repeater is not being created because it is equal to "Nothing". I can...
0
8445
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8356
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8781
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8551
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6198
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5664
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4369
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2771
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1776
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.