This is a migrated thread and some comments may be shown as answers.

[Solved] Spacing between items in grid

3 Answers 740 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Soren Michelsen
Top achievements
Rank 1
Soren Michelsen asked on 08 Oct 2009, 01:37 PM
I'd like to put a (in this case) very slim spacer between each line in my grid.
See attached image.

Any ideas?

Jeppe Jespersen
Denmark

3 Answers, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 08 Oct 2009, 03:22 PM
Hi Jeppe,

You should define a bottom border for the data cells - set the border color and width according to your preference. For example:

CSS

div.RadGrid  .rgRow  td,
div.RadGrid  .rgAltRow  td
{
         border-bottom: 5px solid red;
}


Regards,
Dimo
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Soren Michelsen
Top achievements
Rank 1
answered on 10 Oct 2009, 09:38 AM
Hi again,

Hmm... that doesn't do quite what i'd like.

Your style sets the bottom border, but that means that the left is still "unbroken" and continues all the way down through the grid.

I would like to insert a spacer between rows, so that the left border is not part of the "spaced space". :o)

Not sure if I am making myself clear, but compare the attached grid-margin2.jpg with the previously posted grid-margin.jpg image, and I think you get the idea :-)

Thanks,
Jeppe

0
Dimo
Telerik team
answered on 12 Oct 2009, 01:01 PM
Hi Jeppe,

If I understand you correctly, what you want to achieve is not possible. You can use CellSpacing, but this will insert spacing between columns as well, not just rows.

At any rate, if you know how to achieve the required layout with an ordinary asp:Table (or simply a <table> element), I will show you how to do it with RadGrid.

Kind regards,
Dimo
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Grid
Asked by
Soren Michelsen
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Soren Michelsen
Top achievements
Rank 1
Share this question
or