Is it possible to raise events on a subform's form, when that subform is bound to a table?

前端 未结 2 631
逝去的感伤
逝去的感伤 2021-01-13 00:20

I\'ve got a form with a subform which is bound to a temporary table. The temporary table contains the result of a pivot, but I\'d like users to be able to edit that pivot an

2条回答
  •  失恋的感觉
    2021-01-13 00:51

    It's because the subform object isn't a form having a code module. Thus, nowhere is the event procedure to run.

    So, create a form in datasheetview using the table as source, having no code module, and use that as the subform:

    • Your code is ignored.

    Now, adjust the form to have a code module:

    • Your code runs as expected.

    Anyway, that's how it works for me in Access 2016.

提交回复
热议问题