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

New Rad Grid install does not update image path when using custom skin

5 Answers 308 Views
Grid
This is a migrated thread and some comments may be shown as answers.
hammdo
Top achievements
Rank 1
hammdo asked on 05 May 2008, 01:00 PM
I'm using one of the older css (green) for the new RadGrid.  The css shows up fine (I've turned off the EnableEmbeddedSkins)

I've set the css path to:

<

link href="css/Green/Grid.Green.css" rel="stylesheet" type="text/css" />

In my master page -- the grid shows up green, but the images are not showing up AND it does not update all of the image paths.

I've set the image path to:

css\green\grid

and the css is in
css\green

It will update some of the images but not all in the grid.  It also does not show the images for the one's it has updated.  Have I missed somthing? (grid below).

Also, when I try to use the filter drop down, it appears to not know what skin to apply (its has no style).

What is needed for that to appear?

(BTW -- the images are in the web path and are named the same:
css\green\grid\)

<telerik:RadGrid ID="RadGrid1" runat="server" GridLines="None" AllowFilteringByColumn="True" AllowSorting="True" DataSourceID="SqlDataSource1" ShowGroupPanel="True" Skin="Green" EnableEmbeddedSkins="False" ImagesPath="css\green\grid">

<MasterTableView AutoGenerateColumns="False" DataKeyNames="part_id" DataSourceID="SqlDataSource1" >

<RowIndicatorColumn Visible="False" FilterImageUrl="css\green\grid\Filter.gif" SortAscImageUrl="css\green\grid\SortAsc.gif" SortDescImageUrl="css\green\grid\SortDesc.gif">

<HeaderStyle Width="20px" />

</RowIndicatorColumn>

<ExpandCollapseColumn Resizable="False" Visible="False" CollapseImageUrl="css\green\grid\SingleMinus.gif" ExpandImageUrl="css\green\grid\SinglePlus.gif" FilterImageUrl="css\green\grid\Filter.gif" SortAscImageUrl="css\green\grid\SortAsc.gif" SortDescImageUrl="css\green\grid\SortDesc.gif">

<HeaderStyle Width="20px" />

</ExpandCollapseColumn>

<EditFormSettings>

<PopUpSettings ScrollBars="None" />

<EditColumn CancelImageUrl="Cancel.gif" EditImageUrl="Edit.gif" FilterImageUrl="Filter.gif"

InsertImageUrl="Insert.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif"

UpdateImageUrl="Update.gif">

</EditColumn>

</EditFormSettings>

<Columns>

<telerik:GridBoundColumn DataField="part_id" DataType="System.Int32" HeaderText="part_id"

ReadOnly="True" SortExpression="part_id" UniqueName="part_id" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="part_nbr" HeaderText="part_nbr" SortExpression="part_nbr"

UniqueName="part_nbr" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="part_msuf" HeaderText="part_msuf" SortExpression="part_msuf"

UniqueName="part_msuf" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="part_nm" HeaderText="part_nm" SortExpression="part_nm"

UniqueName="part_nm" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="program_cd" HeaderText="program_cd" SortExpression="program_cd"

UniqueName="program_cd" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="site_cd" HeaderText="site_cd" SortExpression="site_cd"

UniqueName="site_cd" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="type_cd" HeaderText="type_cd" SortExpression="type_cd"

UniqueName="type_cd" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="hert" HeaderText="hert" SortExpression="hert"

UniqueName="hert" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridCheckBoxColumn DataField="is_active" DataType="System.Boolean" HeaderText="is_active"

SortExpression="is_active" UniqueName="is_active" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridCheckBoxColumn>

<telerik:GridCheckBoxColumn DataField="is_reported" DataType="System.Boolean" HeaderText="is_reported"

SortExpression="is_reported" UniqueName="is_reported" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridCheckBoxColumn>

<telerik:GridBoundColumn DataField="part_group" HeaderText="part_group" SortExpression="part_group"

UniqueName="part_group" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="part_group_text" HeaderText="part_group_text"

SortExpression="part_group_text" UniqueName="part_group_text" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridCheckBoxColumn DataField="is_new" DataType="System.Boolean" HeaderText="is_new"

SortExpression="is_new" UniqueName="is_new" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridCheckBoxColumn>

<telerik:GridBoundColumn DataField="full_name" HeaderText="full_name" ReadOnly="True"

SortExpression="full_name" UniqueName="full_name" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="PartName" HeaderText="PartName" ReadOnly="True"

SortExpression="PartName" UniqueName="PartName" FilterImageUrl="Filter.gif" SortAscImageUrl="SortAsc.gif" SortDescImageUrl="SortDesc.gif">

</telerik:GridBoundColumn>

</Columns>

<CommandItemSettings AddNewRecordImageUrl="AddRecord.gif" RefreshImageUrl="Refresh.gif" />

<PagerStyle FirstPageImageUrl="PagingFirst.gif" LastPageImageUrl="PagingLast.gif"

NextPageImageUrl="PagingNext.gif" PrevPageImageUrl="PagingPrev.gif" />

</MasterTableView>

<ClientSettings AllowColumnsReorder="True" ReorderColumnsOnClient="True" AllowDragToGroup="True">

<Selecting AllowRowSelect="True" />

</ClientSettings>

<PagerStyle FirstPageImageUrl="PagingFirst.gif" LastPageImageUrl="PagingLast.gif"

NextPageImageUrl="PagingNext.gif" PrevPageImageUrl="PagingPrev.gif" />

</telerik:RadGrid>



-Thanks! 
-Don

5 Answers, 1 is accepted

Sort by
0
hammdo
Top achievements
Rank 1
answered on 07 May 2008, 03:43 PM
OK, I've been able to get the filter menu to use a menu skin.  I had to create a 'menu' directory and a css with the images (since I'm using ASP.NET themes).  I had to (in code), set the following options for the menu:

this.RadGrid1.FilterMenu.EnableEmbeddedSkins = false;

this.RadGrid1.Grid.FilterMenu.Skin = "Green";

in order for the new skin to show up.

The original issue still stands -- it does not update all of the image paths when I set that option for the grid.

I can attach the 'skins' for those who want to see how I did this...

(BTW, there is not 'attach' available for me to do that here).

-Don

0
Dimo
Telerik team
answered on 08 May 2008, 08:09 AM
Hi Don,

When using a custom skin for RadGrid, you don't have to set explicitly the EnableEmbeddedSkins and Skin properties for the FilterMenu. The only thing to do is register the respective skin for RadMenu on the page (e.g. via a theme).

As for the RadGrid images - as far as I can see, some of the image urls in the RadGrid declaration are not valid, please go through them and make the necessary corrections (some urls are missing the css\green\grid part, e.g. in the EditColumn). By the way, you don't have to explicitly set image urls for images, which are located inside the ImagesPath folder - RadGrid will use those automatically.

The only thing you need to add is a CSS style for the group panel sort images:


.GroupPanel_Green  .rgSortAsc,
.GroupPanel_Green  .rgSortDesc
{
    width:........px;
    height:.......px;

    border:0;
    padding:0;
    background-color:transparent;
    background-repeat:no-repeat;
    background-position:center center;
    vertical-align:middle;
    cursor:pointer;
}

.GroupPanel_Green  .rgSortAsc
{
    background-image:url(.......);
}

.GroupPanel_Green  .rgSortDesc
{
    background-image:url(.......);
}


Let us know if you need more information.


All the best,
Dimo
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Saumil
Top achievements
Rank 1
answered on 30 Sep 2011, 05:48 AM
Hi Dimo,

I'm facing one of the issues mentioned in this post.

After upgrading to the latest (2011) dlls, my custom theme was not working. I prepared a new theme and made changes for radgrid. As for radMenu (I'm using it as navigation panel), I made changes and prepared a new "NewVersion.Menu.Global.css".
These things worked fine, but the filter menu is not coming up fine. I applied the skin name ("Global") and set EnableEmbeddedSkins to false, but it does not make any changes. The radgrid is using the theme "NewVersion".

In your reply, you have mentioned about registering the skin, can you please let me know what exactly needs to be done.

Regards,
Saumil
0
Princy
Top achievements
Rank 2
answered on 30 Sep 2011, 06:02 AM
Hello Saumil,

Check the following help documentation to know about how to register a Skin.
Skin registration

Thanks,
Princy.
0
Saumil
Top achievements
Rank 1
answered on 30 Sep 2011, 06:38 AM
Hi Princy,

Thanks for your reply, but it didnt solve the issue. I am completely stuck because of Telerik upgrade, and would appreciate some help for this issue.

I'm attaching the folder structure of my skins/themes. (skin.jpg)
- Grid is using skin = "NewVer" [NewVer folder in App_Themes]
- RadMenu for navigation panel has skin = "Global"

As per your reply, I registered the "NewVer.Menu.Global.css" stylesheet on the page, but result is still the same. Please check the attached snapshot of FilterMenu on the radGrid.

Regards,
Saumil
Tags
Grid
Asked by
hammdo
Top achievements
Rank 1
Answers by
hammdo
Top achievements
Rank 1
Dimo
Telerik team
Saumil
Top achievements
Rank 1
Princy
Top achievements
Rank 2
Share this question
or