0

My Goal


I want to make it so that, on first run, my program will make its icon appear in the Windows 7 Taskbar. I know that the icon files are shortcuts in C:\Users\USERNAME\AppData\Roaming\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar and mostly want to know this:

My Questions


  1. How, in Java, can I create a shortcut file (.lnk)
  2. Is it possible to even access that without admin privileges?
Cody Gray - on strike
  • 239,200
  • 50
  • 490
  • 574
Ky -
  • 30,724
  • 51
  • 192
  • 308
  • Related: http://stackoverflow.com/questions/1629393/is-it-possible-to-pin-to-start-menu-using-innosetup – Josh Lee Oct 24 '10 at 13:10

2 Answers2

1

You should not need admin privileges but you do need to do this in context of the user whose taskbar is being changed.

Here's a library which does what you want: http://alumnus.caltech.edu/~jimmc/jshortcut/

atamanroman
  • 11,607
  • 7
  • 57
  • 81
1

There is a Java library providing the new Windows 7 features for Java. It's called J7Goodies by Strix Code. Applications using it can be properly pinned to the Windows 7 taskbar. You can also create your own jump lists, etc.

torn
  • 609
  • 6
  • 7