Need to pass progress events from dll

4 posts, 0 answers
  1. David
    David avatar
    159 posts
    Member since:
    Mar 2014

    Posted 19 Mar 2015 Link to this post

    I need to setup progress area for lengthy logic that located in dll outside the page.

    Not sure how to approach this.

    Please help
  2. Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 20 Mar 2015 Link to this post

    Hi David,

    This is how you can start Custom Progress:

    protected void Button1_Click(object sender, EventArgs e)
    {
        RadProgressContext context = RadProgressContext.Current;
        context.SecondaryTotal = "100";
        for (int i = 1; i < 100; i++)
        {
            context.SecondaryValue = i.ToString();
            context.SecondaryPercent = i.ToString();
            context.CurrentOperationText = "Doing step " + i.ToString();
            if (!Response.IsClientConnected)
            {
                //Cancel button was clicked or the browser was closed, so stop processing
                break;
            }
            // simulate a long time performing the current step
            System.Threading.Thread.Sleep(100);
        }
    }

    I hope this helps.

    Regards,
    Hristo Valyavicharski
    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.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. David
    David avatar
    159 posts
    Member since:
    Mar 2014

    Posted 20 Mar 2015 in reply to Hristo Valyavicharski Link to this post

    Hristo,

       My question is regarding situation with logic located in dll. In case my problem isn't clear, from inside the dll i can't access Progress Area which is on the page.
       Is there some way to send updates to Progress Area from dll?
  5. Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 20 Mar 2015 Link to this post

    There is no way to access RadProgressArea from external assembly. I suggest that you refer this assembly to your web application and call the logic from the code behind of the web page where the RadProgressArea is.

    Regards,
    Hristo Valyavicharski
    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.

     
Back to Top