Legato function for imported MIDI?

When I import a MIDI file, I often find that the notes are not legato (which is important for correct singing voice). The only way I’ve found to connect these notes is to do it manually …

Is there a function or script for Synth V which can connect the notes full legato or do I have to do this in my DAW?

Select all the notes. Then run this script.