set_value() does not work properly in 2009-311?

5 posts, 0 answers
  1. Alex
    Alex avatar
    15 posts
    Member since:
    Dec 2008

    Posted 14 Mar 2009 Link to this post

    I am trying to use RadToolBar together with radprompt() as described in your KB article

    http://www.telerik.com/support/kb/aspnet-ajax/window/using-radprompt-and-radconfirm-with-telerik-navigational-controls.aspx

    Everything works as expected - I get the prompt dialog and I enter value, but inside code behind e.Item.Value is always empty.

    I traced javascript with FireBug and I can see that "lastClickedItem.set_value(args)" gets called with "args" having valid string value. But when few moments later I stop at the breakpoint inside "protected void RadToolBar1_ButtonClick" - e.Item.Value = empty string.

    Could you please verify that this KB is still valid for build 2009-311 and suggest a workaround or alternative solution?

    Thank you

    Alexander



  2. Yana
    Admin
    Yana avatar
    4554 posts

    Posted 17 Mar 2009 Link to this post

    Hello Alex,

    Thank you for contacting us.

    I tested the project from the kb article and it worked without a problem.  Please make sure that you're using toolbar.trackChanges() and toolbar.commitChanges() when setting the value. If this doesn't help, send us a simple working example which we can debug. Thanks


    Best wishes,
    Yana
    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.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Alex
    Alex avatar
    15 posts
    Member since:
    Dec 2008

    Posted 17 Mar 2009 Link to this post

    Thank you for looking into this one!

    Here is a test project that I made that shows the problem.

    There are two main differences that this project has from "clean" sample from blog article

    - It uses master pages
    - RadToolBar is placed on top of the form view

    Here is a full project (without Rad dll)

    Run WebForm1.aspx to see problem

    http://test20090111.s3.amazonaws.com/RadConfirmDemo.zip

    I really appreciate your help


    Alexander
  5. Yana
    Admin
    Yana avatar
    4554 posts

    Posted 18 Mar 2009 Link to this post

    Hi Alex,

    Thank you for preparing the project.

    The problem is that the FormView is databinded on every postback. To avoid this you should bind it in Page_Load like this:

    if (!IsPostBack)  
    {  
        var data = new List<string>();  
        data.Add("one item");  
        cameraView.DataSource = data;  
        cameraView.DataBind();  

    Now the corrected value is returned.

    Regards,
    Yana
    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.
  6. Alex
    Alex avatar
    15 posts
    Member since:
    Dec 2008

    Posted 19 Mar 2009 Link to this post

    Thank you, that fixed the problem.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017