How to trigger "Refresh" programmatically?

7 posts, 0 answers
  1. Tim
    Tim avatar
    57 posts
    Member since:
    Oct 2013

    Posted 15 Jul 2014 Link to this post

    Dear All,

    Is that a possible way that I can pull the exact function of the "Refresh" as shown in the attachment?

    Thank you and Regards.
  2. Tim
    Tim avatar
    57 posts
    Member since:
    Oct 2013

    Posted 16 Jul 2014 Link to this post

    Anyone can give a hand? I'm asking the question because I was following this telerik demonstration to build a drill down pivotgrid. However it stops working when I switch the fields until I need to press the "Refresh" manually. I've tried using Rebind(), but that doesn't do the trick.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Tim
    Tim avatar
    57 posts
    Member since:
    Oct 2013

    Posted 18 Jul 2014 Link to this post

    I don't think it'll be that difficult but I've not clue where to start, any suggestions to this work around?
  5. Viktor Tachev
    Admin
    Viktor Tachev avatar
    1488 posts

    Posted 18 Jul 2014 Link to this post

    Hi Tim,

    The issue you describe seems rather strange. You could try couple of things that could help point us in the right direction.

    Would you check the browser console and ensure that there are no JavaScript errors on the page? Would you also try disabling Ajax on the page and let me know if the behavior changes?


    Regards,
    Viktor Tachev
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  6. Tim
    Tim avatar
    57 posts
    Member since:
    Oct 2013

    Posted 18 Jul 2014 in reply to Viktor Tachev Link to this post

    Hi Viktor, 

    Thanks for the reply, it's not actually an error, but more of incompatibility between the drill down functionality and my project. Sorry for overly simplifying the question.

    As we know the key principal of the drill down functionality is to allow the users to read what filters the cell is under when user clicks: for instance from the demo, wheres give the filter and their corresponding values.

    Extracted codes from demo:
    string[] groups = e.CommandArgument.ToString().Split(new char[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
                    StringBuilder wheres = new StringBuilder();

                    if (groups.Count() > 0)
                    {
                        string[] elements = groups[0].Split(new char[] { ';' }, StringSplitOptions.RemoveEmptyEntries);
                        foreach (var element in elements)
                        {
                            var pairs = element.Split(new char[] { '~' }, StringSplitOptions.RemoveEmptyEntries);
                            wheres.Append(string.Format("{0} = '{1}' AND ", pairs[0], pairs[1]));
                        }

    The problem occurs when I change my filters, the e.CommandArgument will continue to read the old filter value, and this can only be corrected by clicking the "Refresh" button manually. That's why giving the question as described.

    Thanks.
  7. Viktor Tachev
    Admin
    Viktor Tachev avatar
    1488 posts

    Posted 23 Jul 2014 Link to this post

    Hi Tim,

    I am afraid that without debugging the code it would be hard to determine what is causing the old filter values to be applied.

    Would you build a runnable project where the issue is replicated and send it to us in a support ticket? This would allow us to thoroughly investigate the issue and look for its cause.


    Regards,
    Viktor Tachev
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  8. Tim
    Tim avatar
    57 posts
    Member since:
    Oct 2013

    Posted 25 Jul 2014 in reply to Viktor Tachev Link to this post

    Hi Viktor, I'll gladly do. Thanks!
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017