Hi! I don't know so good to work with $com objects, but i need a script (alias) using $com objects that will return the same thing as in the following vbScript code:
stPath="C:\Users\*\Desktop\mIRC.lnk"
Set wshShell=CreateObject("WScript.Shell")
Set objShortcut=wshShell.CreateShortcut(stPath)
WScript.Echo "Target Path: " & objShortcut.TargetPath
This Code will show me the target path of the indicated shortcut when i execute the shortcut.vbs
So, if somebody helps me to create an alias (/shortcut), for example, when i execute:
//echo -a $shortcut("C:\Users\Administrator\Desktop\mIRC.lnk")
will return the target path value of the input shortcut.
P.S. Will be good the alias to be created using the method of vbscript commands listed above.
Also i have, for example, an idea to save it in a vbs file and to use /run command, the value to be written in a file and so on.. but will be good if i implement this using $com objects instead.
Thanks any who will help me with this alias.