Create Moving Object

 
Hi guys, my question is simple, while creating a horizontal line I'd like to make it possible for the user to move it in case my algorith miscalculates it's placing.
For example when you manually create a horizontal line you can drag it up and down. But when you programmatically create it you cannot. How do I make it possible for a user to move it by dragging it around?
 
Mercilex But when you programmatically create it you cannot. How do I make it possible for a user to move it by dragging it around?
Make it selectable and/or select it
 

I don't know how I did miss this. Thanks!

Edit: excuse the noob question again, but what is the property which displays where the HLINE stands at? 

Edit2: NVM found it: OBJPROP_PRICE

 
Sometimes its better we research before asking questions first.