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

CSS Files not loading

5 Answers 334 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
FinallyInSeattle
Top achievements
Rank 1
FinallyInSeattle asked on 27 Sep 2011, 12:47 AM
I have a POC project where your grid display correctly - CSS files load properly (verified by doing a "View Source").  I've incorporated all the same changes (web.config changes, StyleSheetRegistrar, ScriptRegistrar) and the CSS files do not load.  There's no error indicating that the files can't be found and there's no link statements in the source.  Here's my StyleSheetRegistrar statement - turned off combining and compressing in order to test.  Can someone assist me with why the styles aren't loading?  Thanks in advance!
@{Html.Telerik().StyleSheetRegistrar()
                .DefaultGroup(group => group.Add("telerik.common.min.css")
                                        .Add("telerik.office2010blue.min.css")
                                        .CacheDurationInDays(5)
                                        .Combined(false)
                                        .Compress(false)).Render();}

@{Html.Telerik().Grid(Model.Order.SalesOrder.SalesOrderNotes)
        .Name("GridNotes")
        .Columns(columns =>
        {
            columns.Bound(o => o.DateCreated);
            columns.Bound(o => o.Note);
            columns.Bound(o => o.CreatedBy);
        })
        .Sortable()
        .Render();                               
}
 
@{Html.Telerik().ScriptRegistrar().DefaultGroup(group => group.Combined(false)
                                                         .CacheDurationInDays(5)
                                                         .Compress(false))
                                                         .jQuery(false)
                                                         .Render();
}

5 Answers, 1 is accepted

Sort by
0
Rosen
Telerik team
answered on 27 Sep 2011, 08:09 AM
Hello Lori,

Unfortunately, the provided information is not sufficient in order to track the cause of such behavior. Therefore, please provide a small sample in which this can be observed.

Regards,
Rosen
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now
0
FinallyInSeattle
Top achievements
Rank 1
answered on 27 Sep 2011, 05:45 PM
Here's a stripped down sample - note the grid at the bottom of the page.
0
Rosen
Telerik team
answered on 28 Sep 2011, 11:52 AM
Hi Lori,

Thank you for the sample project. In your scenario you should render the StyleSheetRegistrar directly instead of calling the Render method:

@(Html.Telerik().StyleSheetRegistrar()
     .DefaultGroup(group => group.Add("telerik.common.min.css")
                             .Add("telerik.office2010blue.min.css")
                             .CacheDurationInDays(5)
                             .Combined(false)
                             .Compress(false)))


Regards,
Rosen
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now
0
FinallyInSeattle
Top achievements
Rank 1
answered on 28 Sep 2011, 06:24 PM
Thanks for your assistance!  However, when I apply that change to the sample project that I sent, the CSS files are still not being loaded.
0
Accepted
Rosen
Telerik team
answered on 29 Sep 2011, 09:47 AM
Hello Lori,

Could you please verify that correct brackets (those @( ) instead of those @{ }) are used as shown in the sample pasted in my previous message.

Regards,
Rosen
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now
Tags
Grid
Asked by
FinallyInSeattle
Top achievements
Rank 1
Answers by
Rosen
Telerik team
FinallyInSeattle
Top achievements
Rank 1
Share this question
or