More in this section

Forums / Developing with Sitefinity / Problem with updating User Control

Problem with updating User Control

7 posts, 0 answered
  1. Aaron
    Aaron avatar
    24 posts
    Registered:
    15 Feb 2008
    13 Jun 2008
    Link to this post
    I have a User Control that I have uploaded in Sitefinity and put on a page.  The User Control is in the "User Control" folder like usual.  However, whenever I edit the User Control in Visual Studio and then refresh the page in Sitefinity Edit, Preview or even Publish windows, I do not see the changes.  Is there a way to get it to pull in the latest changes from the User Control without having to re-upload the control in Sitefinity?

    In this case, my User Control contains a RadGrid, SqlDataSource and some text.
  2. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    17 Jun 2008
    Link to this post
    Hello Christopher,

    Please confirm that you have edited the right copy of the user control, and it is actually the one defined in the <toolboxControls> section in the application web.config file.

    Sitefinity always takes the custom user controls from the file system so the last change should be reflected immediately after it's made.

    We apologize for not being able to help you further, but we see no way to replicate this issue. If you still experience this problem, please provide the exact steps we should take to see this behavior.

    Best wishes,
    Georgi
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Aaron
    Aaron avatar
    24 posts
    Registered:
    15 Feb 2008
    17 Jun 2008
    Link to this post
    Thanks Georgi.  Upon closer inspection I realized I was updating the wrong User Control in Visual Studio.  So it does work just as you said.

    Thanks
  4. mattc
    mattc avatar
    105 posts
    Registered:
    11 Aug 2007
    04 Nov 2009
    Link to this post
    Hi all

    I seem to be having this problem too. Using Win7 and VS2008

    When I change the user control in the file system (where SF uploaded it ~/UserControls) any pages with this user control in them don't show the changes. All I'm adding at the moment  is an <H2> tag in the .ascx file..

    If I create a new page and add the user control to it it displays the new version.
    I go to the old page and it's displaying the old version still.

    Is this how it's meant to be? I'm planning on writing user controls that will be on lots of pages and I need them to update in all pages containing them when I change the source.



  5. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    05 Nov 2009
    Link to this post
    Hi mattc,

    Most probably your pages are cached. Can you please check if you have caching enabled? Your pages will be refreshed with the changes once the cached information expire.

    Greetings,
    Georgi
    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.
  6. mattc
    mattc avatar
    105 posts
    Registered:
    11 Aug 2007
    05 Nov 2009
    Link to this post
    Hi Georgi

    Thanks, this morning it worked... I didn't have any caching turned on in Sitefinity, could be a browser or Win7 thing but don't think so.
    I have been working on modifying properties of controls through the API and I must be doing something wrong still as when I run the code to change the value of the property it no longer reflects any changes I make to the user control in VS. I will post on that thread:
    http://www.sitefinity.com/support/forums/sitefinity-3-x/developing-with-sitefinity/update-property-of-control.aspx

    Thanks
  7. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    05 Nov 2009
    Link to this post
    Hello mattc,

    We will follow up in other forum thread.

    Greetings,
    Georgi
    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.
Register for webinar
7 posts, 0 answered