We're trying to get this working with some large scripts we have.
The help seems woefully small given the complexity of what is going on here - most of the properites aren't documented.
We added several scripts with the default settings, but nothing seems to be happening.
Here's the code in our test web page:
As you can see, we have the default settings. We see no difference in HTTPWatch whatsoever. If we move the JS files out from the script manager, it looks exactly the same. The files do not seem to combine nor do they seem to compress.
Is there something more we need to configure?
Thanks,
Nick H
The help seems woefully small given the complexity of what is going on here - most of the properites aren't documented.
We added several scripts with the default settings, but nothing seems to be happening.
Here's the code in our test web page:
<telerik:RadScriptManager ID="ScriptManager1" runat="server"> |
<Scripts> |
<asp:ScriptReference Path="/midas.js" /> |
<asp:ScriptReference Path="/midas2.js" /> |
</Scripts> |
</telerik:RadScriptManager> |
As you can see, we have the default settings. We see no difference in HTTPWatch whatsoever. If we move the JS files out from the script manager, it looks exactly the same. The files do not seem to combine nor do they seem to compress.
Is there something more we need to configure?
Thanks,
Nick H
7 Answers, 1 is accepted
0
Hello Nick,
This is by design. RadScriptManager does not combine script references which have only Path set. RadScriptManager can combine only javascript files which are embedded as resources.
All the best,
Albert
the Telerik team
Check out Telerik Trainer , the state of the art learning tool for Telerik products.
This is by design. RadScriptManager does not combine script references which have only Path set. RadScriptManager can combine only javascript files which are embedded as resources.
All the best,
Albert
the Telerik team
Check out Telerik Trainer , the state of the art learning tool for Telerik products.
0

Nick
Top achievements
Rank 2
answered on 25 Mar 2009, 05:11 PM
So there is no point in sending a .js files to the radscriptmanager then?
0

Nick
Top achievements
Rank 2
answered on 25 Mar 2009, 05:29 PM
Ok after doing some research on embedded resources with javascripts, I see it's actually pretty easy to create them - property change on the .CS file.
Is it possible get a sample showing how to properly implement this with radscriptmanager, i.e. I see how to create the enbedded resource, but the samples I am finding are a bit confusing and of course don't show how to integrate it with radscriptmanager.
I would think this could be valuable to a lot of people.
Is it possible get a sample showing how to properly implement this with radscriptmanager, i.e. I see how to create the enbedded resource, but the samples I am finding are a bit confusing and of course don't show how to integrate it with radscriptmanager.
I would think this could be valuable to a lot of people.
0
Hi Nick,
By all means. Please find attached a sample solution which demonstrates how to embed javascript files as web resources and then combine them with RadScriptManager.
Regards,
Albert
the Telerik team
Check out Telerik Trainer , the state of the art learning tool for Telerik products.
By all means. Please find attached a sample solution which demonstrates how to embed javascript files as web resources and then combine them with RadScriptManager.
Regards,
Albert
the Telerik team
Check out Telerik Trainer , the state of the art learning tool for Telerik products.
0

Connections Academy Developer
Top achievements
Rank 1
answered on 30 Apr 2009, 04:10 PM
Your example is helpful, but it only shows how to add a ScriptReference by referring to its DLL/Assembly. I am looking for an example that shows how to do something such as:
RadScriptManager scriptManager = new RadScriptManager();
scriptManager.Scripts.Add(new ScriptReference(url));
This isn't working for me - none of the url's I pass to this call:
scriptManager.Scripts.Add(new ScriptReference(url));
end up being rendered to the page by the call to the Telerik.Web.UI.WebResource.axd.
Please advise, thank you.
0
Hello,
As explained earlier in this thread RadScriptManager does not combine scripts referenced by url. Only scripts embedded as web resources are combined.
All the best,
Albert
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
As explained earlier in this thread RadScriptManager does not combine scripts referenced by url. Only scripts embedded as web resources are combined.
All the best,
Albert
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0

Connections Academy Developer
Top achievements
Rank 1
answered on 30 Apr 2009, 04:18 PM
Yes, I understood that it wouldn't combine them - but I at least expected that it would render them in some fashion. Essentially, you can't register scripts by URL at all, yet the method/code would make one believe that it is allowed and supported.