How to access a line in a drawing (0r a sheet) and change its angle from LO Basic

Hi
I’m trying to create and edit lines in a separate drawing document, or in a spreadsheet doc, or even an embedded drawing - from results of spreadsheet calculations.
Can someone point me at the appropriate documentation for this? I’ve looked at lots of stuff, but still in the dark . . .
Cheers :slight_smile:

Danny’s Draw PowerTools.odg (88.5 KB)