none
Possible bug with BindingDataChanged event RRS feed

  • Question

  • Hi,

    So basically I've subscribed binding object on BindingDataChanged and BindingSelectionChanged events and everything works perfectly fine until I make "double click" (or multiple clicks) let's say in the middle of document (I'm talking about Word). After that handler for BindingDataChanged never triggers. Handler for BindingSelectionChanged still works perfectly fine.

    I though that it was bug in my code, so I created brand new project and made some tests, but still got the same result.

    Best Regards,

    Milos

    Friday, April 22, 2016 2:10 PM

All replies

  • Hi Milos,

    Did you test BindingDataChanged in word client or word online and what your office version? I made a test with below code by following your steps at word 2013 client, but I failed to reproduce your issue. It worked correctly at my side.

    function BindingDataChangedEvent() {
    
        Office.context.document.bindings.addFromSelectionAsync(Office.BindingType.Text, { id: "BindingId" }, function (asyncResult) {
    
            asyncResult.value.addHandlerAsync(Office.EventType.BindingDataChanged, function (eventArgs) {
    
                app.showNotification('binding changed '+ eventArgs.binding.id);
    
            });
    
        });
    
    }
    

    To check whether it is related with your code, I suggest you test above code, if it did not exist, it would be helpful if you could share us your simple code.

    Best Regards,

    Edward


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.


    Monday, April 25, 2016 3:27 AM
  • Hi Edward,

    Thank you for reply, I didn't provide enough details, sorry about that. I'm using Word 2016 (not online version),  on Windows 7.

    Here is my code:

    Office.context.document.bindings.addFromSelectionAsync(Office.BindingType.Table, function (result) {
                        binding = result.value;
                        binding.addHandlerAsync(Office.EventType.BindingDataChanged, function (result) {
                            app.showNotification('binding changed ' + result.binding.id);
                        });
                    });

    I also uploaded video with all the steps which cause the problem:
    https://www.youtube.com/watch?v=3pcaVaewthg

    Best Regards,

    Milos





    Monday, April 25, 2016 11:31 AM
  • Hi m41in4,

    Thanks for details information.

    I made a test following your video, and I could reproduce your issue. I suggest you submit a feedback in the link below:

    http://officespdev.uservoice.com

    Best Regards,

    Edward


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.


    Tuesday, April 26, 2016 7:07 AM
  • Thanks for reporting this issue. I was looking into it  and I was NOT able to repro this behavior, the event is working properly.

    btw i saw a minor issue with your code you are not declaring the binding variable.

    Anyways... Can you please reply if you are still experiencing this issue? and also please include your build number. thanks!

    Thursday, September 22, 2016 11:07 PM
    Moderator
  • Hi Juan,

    Thanks for your help.

    I made a test again with latest Office Developer tools, it seems this issue still exists. To reproduce this issue, I think you need to process multiple double click in the center of the document after you addFromSelectionAsync for Table.

    Best Regards,

    Edward


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.


    Saturday, September 24, 2016 4:17 AM
  • Hi Edward, I tried again and i am not able to repro.

    Please contact me @ msft at this point i want to have a conf call with you and see this issue.

    thansk!

    Monday, October 31, 2016 9:56 PM
    Moderator