Quantcast
Channel: AjaxControlToolkit Work Item Rss Feed
Viewing all articles
Browse latest Browse all 4356

Commented Unassigned: ClientCssResource : css lot loaded [27988]

$
0
0
Hello,

We have a problem with ClientCssResource.
We upgraded a old version of ajaxcontroltoolkit : 3.5.7.123 to 15.1.4.
(see this issue : https://ajaxcontroltoolkit.codeplex.com/workitem/27986)

we are using ajax server control that inherit from other ajaxcontroltoolkit controls, like explained in this tutorial :
http://code.tutsplus.com/tutorials/asp-net-ajax-server-controls-with-client-side-functionality--net-26166

So we included CSS file like ressource embedded :

```
[assembly: WebResource("PluginControl.PluginTest.js", "application/x-javascript")]
[assembly: WebResource("PluginControl.PluginTest.css", "text/css")]
namespace PluginControl
{
[ClientScriptResource("PluginControl.PluginTest", "PluginControl.PluginTest")]
[ClientCssResource("PluginControl.PluginTest.PluginTest.css")]
public class PluginTest : ScriptControlBase
{}
}
```
But with new version the css is not loaded and no error or warning is display.
Can you help with this issue please ?

I join file with the problem, as you can see PluginTest.css is not loaded.

Thank in advance,



Comments: In the current version of AJAX Control Toolkit, all CSS resource paths in the _WebResource_ attribute must have the "AjaxControlToolkit.Styles."  prefix, while the _ClientCssResource_ attribute does not have the ".css" suffix. In your case, it will look like this: ``` [assembly: WebResource("AjaxControlToolkit.Styles.PluginControl.PluginTest.css", "text/css")] ... [ClientCssResource("PluginControl.PluginTest")] ``` I have updated the sample project you provided and attached the new version to this issue. Please let me know is this change helped you.

Viewing all articles
Browse latest Browse all 4356

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>