Looking for a way to ID PC’s that have a specifically named shortcut on the users desktop.
exists file “C:\Documents and Settings{name of current user}\Desktop\myshortcut.lnk”
“myshortcut.lnk” does exist at that location but relevance shows false. I think it is because the extension “.lnk” is not displayed or is handled differently than a file. Any ideas on what method I can use would be welcome.
The braces are substitution parameters used only in the Action Script, but not the Relevance Language. So your {name of current user} was treated as a literal string.
The following would be a workable alternative:
exists file (“C:\Documents and Settings” & (name of current user) & “\Desktop\myshortcut.lnk”)
Note that theoretically, a user’s home can be something other than \documents and settings. If you run into that issue, we can only retrieve the home directory dynamically from the registry. But let’s not worry until you have to.