473,396 Members | 1,864 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Datagrid or Repeater - Multiple Columns

Hi All,

I have an app which requires a list of coutries to be displayed, so far I
have a datagrid which contains displays the countries Ok, along with flag
images, these are also links to my dtail page - So far so good (Thanks to
Pete Beech for the assistance in getting this far!)

What I would now like is to spread the countries across multiple columns -
e.g. grid/table with 20 countries, 5 rows X 5 columns. (Currently they are
displayed in 1 column)

Is this possible using either datagrid or repeater controls?

Thanks!

Simon.
--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!
Nov 18 '05 #1
2 7048
Solved it using the datalist control, useful explanation here...
http://it.maconstate.edu/tutorials/A...pnet08-02.aspx

"Simon Harris" <to*********@makesyoufat.com> wrote in message
news:ux**************@tk2msftngp13.phx.gbl...
Hi All,

I have an app which requires a list of coutries to be displayed, so far I
have a datagrid which contains displays the countries Ok, along with flag
images, these are also links to my dtail page - So far so good (Thanks to
Pete Beech for the assistance in getting this far!)

What I would now like is to spread the countries across multiple columns -
e.g. grid/table with 20 countries, 5 rows X 5 columns. (Currently they are
displayed in 1 column)

Is this possible using either datagrid or repeater controls?

Thanks!

Simon.
--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!

Nov 18 '05 #2
Hi Simon,
I would say the DataList would be your best bet, since that has a way of
displaying a list with multiple columns using the RepeatColumns (int) and
RepeatDirection property.

The datagrid can't lay out columns as you want - and I'm not sure about the
Repeater - you might be able to do it, but it won't be as easy as with the
DataList control.

Here are some links - the first one lists all the different options for
displaying lists, (although it isn't actually that clear on laying out
things in a grid style.)

http://msdn.microsoft.com/library/de...ebcontrols.asp
http://msdn.microsoft.com/library/de...listlayout.asp

Cheers,
Pete

"Simon Harris" <to*********@makesyoufat.com> wrote in message
news:ux**************@tk2msftngp13.phx.gbl...
Hi All,

I have an app which requires a list of coutries to be displayed, so far I
have a datagrid which contains displays the countries Ok, along with flag
images, these are also links to my dtail page - So far so good (Thanks to
Pete Beech for the assistance in getting this far!)

What I would now like is to spread the countries across multiple columns -
e.g. grid/table with 20 countries, 5 rows X 5 columns. (Currently they are
displayed in 1 column)

Is this possible using either datagrid or repeater controls?

Thanks!

Simon.
--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!

Nov 18 '05 #3

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

Similar topics

1
by: Lalit Bhatia | last post by:
how can we fix first column in DataGrid? Regards, Lalit Bhatia
0
by: Lalit Bhatia | last post by:
thanks for the answer but I need it for windows forms. I have a desktop application where I need to implement this. -- Regards, Lalit Bhatia "Mona" <mona@discussions.microsoft.com> wrote in...
2
by: Stephen Miller | last post by:
I am using the OnItemDataBound event of Repeater control to nest a DataGrid within the Repeater. When I attempt to bind to the DataGrid using the DataSource method I get the error message "Object...
1
by: Rick | last post by:
Hello all, I hope all is well with you. I am having a seriously difficult time with this problem. Allow me to set up the problem. I have a System.Web.UI.Page with the following controls...
2
by: John Hoge | last post by:
I have a datagrid displaying a number of narrow columns and one very wide one. It would make sense from a layout perspective to have two rows per dataitem, and to put the long descriptive field...
2
by: News | last post by:
Hi I need help to display and edit data in a data grid within a repeater. The code is below: Sub dgrdEvents_EditCommand(sender As Object, e As DataGridCommandEventArgs)...
4
by: News | last post by:
I have a page with many controls. Among these controls there is a table which is a datagrid with nested repeater inside. My problem is that I can not use DataGridCommandEventArgs to get datagrid...
3
by: Maziar Aflatoun | last post by:
Hi everyone, I have a datagrid that I create inside a Repeater at runtime. I have defined a checkbox beside each row so that users can select multiple rows. <asp:datagrid id="dgProducts"...
2
by: mark4asp | last post by:
This page is currently using a Repeater control to create a table with 6 columns. The first column has 2 ImageButton controls and a common header. How can I do this with a DataGrid ? I need...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.