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

Radgrid

1 Answer 30 Views
Grid
This is a migrated thread and some comments may be shown as answers.
dwarak kanniah
Top achievements
Rank 1
dwarak kanniah asked on 24 May 2010, 02:40 PM
HI,

I am using radgrid in my project.I have couple of questions regarding radgrid .

1) Since I do want to use Skins I have set Enable embedded skins property to false and apply styles to the grid.The problem is that vertical borders doesnt appear in IE while in Firefox it shows up.I have posted my code and styles below.

2)Since I want custom page template, using Pager template I am creating Paging for radgrid.I am able to create First,Previous,Next and Last  using that.But I want to have numbers also appeared in middle of Previous and Next.Is there any way displaying numbers horizontally in labels instead of textbox.

Could anyone please solve this issues as soon as possible.its urgent.

For eg the paging style should look as:<< Previous 1 2 3 Next >>.

Code:

 

<telerik:RadGrid ID="ProfileRadGrid" runat="server" GridLines="Both" AllowSorting="True"

 

 

AllowPaging="True" PageSize="5" Height="400px" PagerStyle-AlwaysVisible="true" AutoGenerateColumns="False" EnableEmbeddedSkins="false">

 

 

<HeaderStyle CssClass="gridheader" Wrap="true" />

 

 

<ItemStyle CssClass="gridrow" Wrap="true" BorderColor="Black" BorderStyle="Solid" />

 

 

<AlternatingItemStyle CssClass="gridalternatingrow" Wrap="true" />

 

 

<PagerStyle Mode="NumericPages"/>

 

 

 

<MasterTableView>

 

 

<PagerTemplate>

 

 

<table border="0" cellspacing="0" cellpadding="0" height="18px" width="100%">

 

 

<tr>

 

 

<td style="border-style: none;">

 

 

<asp:LinkButton ID="LinkButton1" CommandName="Page" CausesValidation="false" CommandArgument="First"

 

 

runat="server" CssClass="linkbutton_blue"><<</asp:LinkButton>&nbsp;&nbsp;

 

 

<asp:LinkButton ID="LinkButton5" CommandName="Page" CausesValidation="false" CommandArgument="Prev"

 

 

runat="server" CssClass="linkbutton_blue">Previous Page</asp:LinkButton>&nbsp;&nbsp;

 

 

<asp:LinkButton ID="LinkButton3" CommandName="Page" CausesValidation="false" CommandArgument="Next"

 

 

runat="server" CssClass="linkbutton_blue">Next Page</asp:LinkButton>&nbsp;&nbsp;

 

 

<asp:LinkButton ID="LinkButton2" CommandName="Page" CausesValidation="false" CommandArgument="Last"

 

 

runat="server" CssClass="linkbutton_blue">>></asp:LinkButton>

 

 

</td>

 

 

<td style="border-style: none; white-space: nowrap;">

 

 

</td>

 

 

 

 

</tr>

 

 

</table>

 

 

</PagerTemplate>

 

 

<Columns>

 

 

...................................
.................................
</
Columns>

 

 

</MasterTableView>

 

 

</telerik:RadGrid>

 

 


Style:

.gridheader

{

 

background-color: #c3c3c3;

 

 

font-family: Arial,Times New Roman,Trebuchet MS,Sans-Serif;

 

 

font-size: 13px;

 

 

font-weight:normal;

 

 

text-align: left;

 

 

color: Black;

 

 

text-transform: none;

 

 

text-align: left;

 

 

vertical-align: top;

 

 

border-bottom:solid thin black;

 

 

border-top:solid thin black;

 

 

border-left:solid thin black;

 

 

border-right:solid thin black;

 

 

height: 25px;

 

 

text-align: left;

 

}

.gridheader

 

a

 

{

 

text-decoration:none;

 

 

color: Black;

 

}

.gridrow

{

 

 

 

background-color:White;

 

 

font-family: Arial,Times New Roman,Trebuchet MS,Sans-Serif;

 

 

font-size: 13px;

 

 

text-align: left;

 

 

color: Black;

 

 

text-transform: none;

 

 

vertical-align: top;

 

 

text-decoration:none;

 

 

height: 25px;

 

 

border-bottom:solid thin black;

 

 

border-top:solid thin black;

 

 

border-left:solid thin black;

 

 

border-right:solid thin black;

 

}

.gridrow

 

a

 

{

 

text-decoration:none;

 

 

color: blue;

 

 

}

.gridalternatingrow

{

 

 

 

background-color:White;

 

 

font-family: Arial,Times New Roman,Trebuchet MS,Sans-Serif;

 

 

font-size: 13px;

 

 

text-align: left;

 

 

color: Black;

 

 

text-transform: none;

 

 

vertical-align: top;

 

 

text-decoration:none;

 

 

height: 25px;

 

 

border-bottom:solid thin black;

 

 

border-top:solid thin black;

 

 

border-left:solid thin black;

 

 

border-right:solid thin black;

 

}

.gridalternatingrow

 

a

 

{

 

text-decoration:none;

 

 

color: blue;

 

 

}


Also I have attached how grids look between firefox and ie.

Thanks,
Dwarak

1 Answer, 1 is accepted

Sort by
0
Iana Tsolova
Telerik team
answered on 28 May 2010, 08:59 AM
Hi dwarak,

Please refer to the below online resources for more information on how to add/remove grid lines in RadGrid:
http://www.telerik.com/help/aspnet-ajax/controlling-grid-lines.html
http://www.telerik.com/community/code-library/aspnet-ajax/grid/how-to-add-or-remove-radgrid-borders.aspx

Try the solutions provided there and see if it works for you.

Greetings,
Iana
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
Grid
Asked by
dwarak kanniah
Top achievements
Rank 1
Answers by
Iana Tsolova
Telerik team
Share this question
or