Hixxy's example is just creating a basic shortcut, it is not filling any parameters, but from qwerty's post, you have a link to a snippet that does exactly what you want, for example this is how to set the target path :
$com(com_name,targetpath,4,bstr*,value)