How can I extended one or more midi note to cursor?

I have already watched this tutorial

but it has not been helpful.
Any tips for solving my issue?

Thank you very much

Francesco