Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Shell menu triggers : Shorcuts of a given file type
#1
Shell menu triggers : Is it possible to "Include Files" of "type" lnk (shortcuts) with a given extension, for example pdf? And if yes, how?

Many thanks in advance.
#2
Cannot include lnk files because QM shell menu triggers use the shortcut target file, not the shortcut file. For example, if you specify pdf, the menu item will be added for pdf files and for lnk files that point to pdf files.
#3
Thank you for this very prompt reply. However, perhaps I was misunderstood. For example, the following function is perfectly triggered by shortcuts (lnk) files. My question was if I could confine it to shortcuts of .pdf type :

Function GoTo_Target
Trigger $sm "GoTo Target" 0x40 "lnk" "$user profile$\My Documents\Local Settings\sysman\Icons\Ico\Shortcut2.ICO" "GoTo shortcut target"     Help - how to add the trigger to the macro
Code:
Copy      Help
;\
function $files

str si.getmacro(getopt(itemid) 1)
str caller.getmacro(getopt(itemid 1) 1);err    caller=si
if ideb; min 0; err out "<>%s : <open ''%s /%i''>%s</open> - Called by : %s" NowT si _error.place si caller

str f
int i
foreach f files
,i=i+1
,outt f

if i<>1
,_s=F"Files triggered {i}  - Caller : <open>{caller}</open> "
,min 0; err out "<>%s : <open ''%s /%i''>%s</open> - %s" NowT si _error.place si _s
,mac "Warning_QM" si 0
,end

GoToTarget(f)
#4
On my PC this trigger does not work. Works only if I replace lnk to pdf. But if would work with lnk, the menu item would be added to all lnk files, and there is no way to confine the trigger to lnk files pointing to pdf files.
#5
Thank you for dealing with my questions. This lnk trigger works on my XP PCs since many years ago, with no problem at all. I am screening pdf shortcuts in the "foreach f files" loop, with no problem at all. It is implied that a "and" type trigger (lnk+pdf) - if it existed - it would have been more elegant. Best regards.


Forum Jump:


Users browsing this thread: 1 Guest(s)