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

[Solved] RadComboBox and OutputCache

1 Answer 100 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Daniel (DeDU)
Top achievements
Rank 1
Daniel (DeDU) asked on 17 Oct 2009, 11:40 PM
Hi,

I have a RadComboBox in my MasterPage to search the entire site.

All underlying pages using this MasterPage are using OutputCache. With this configuration it is possible to search one time but after that the combobox is cached and no items is being displayed, no postback, nothing.

I have tried using the same method as:
 - Use RadMenu in a user control with OutputCache enabled
and
- Disabling embedded resources

But the result is that the RadComboBox is dead, It does not change state from "EmptyMessage" to a "SearchString".

I have the latest javascripts (2009.02.0701.35) and the following code in my MasterPage:
<asp:ScriptManager ID="ScriptManager1" runat="server">
        <Scripts>
            <asp:ScriptReference Path="RadControls/Scripts/Common/Core.js" />
            <asp:ScriptReference Path="RadControls/Scripts/Common/Animation/AnimationScripts.js" />
            <asp:ScriptReference Path="RadControls/Scripts/Common/Navigation/NavigationScripts.js" />
            <asp:ScriptReference Path="RadControls/Scripts/Common/Popup/PopupScripts.js" />
            <asp:ScriptReference Path="RadControls/Scripts/Common/Scrolling/ScrollingScripts.js" />
            <asp:ScriptReference Path="RadControls/Scripts/ComboBox/RadComboBoxScripts.js" />            
        </Scripts>
</asp:ScriptManager>

What have I done wrong? Is there an easier approach?

Best Regards,
Andreas

1 Answer, 1 is accepted

Sort by
0
Veselin Vasilev
Telerik team
answered on 21 Oct 2009, 01:27 PM
Hi Andreas,

Here is my last reply from the support ticket of yours:

There are two options here:

1. Enable the OutputCache per user controls only - add the content that you want to cache to user controls and enable the output cache per that controls. The user control that contains the combobox will not have that option enabled and will not be cached. This is so called fragment caching. The opposite is the post-cache substitution - you cache the whole page except some parts of it. Unfortunatelly, I read that it works/dynamically updates only strings which is not viable in our case?!

2. Bind the combobox to a Web Service. This will work no matter the caching. The only drawback is that Web Service binding does not support client templates. If you are not using a multi-column combobox you might not need the ItemTemplate and stick with this method. I have attached the modified project which uses this approach.


Project file

Regards,
Veselin Vasilev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
ComboBox
Asked by
Daniel (DeDU)
Top achievements
Rank 1
Answers by
Veselin Vasilev
Telerik team
Share this question
or