Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pin this program to taskbar option missing in my C# application

All programs I have tried so far in Windows 7 have a 'Pin this program to taskbar' item when right-clicking them in the task bar. I have a C# program that only shows 'Close Window' and nothing else. It is build with C# 2010 Express, and targets .NET 3.5 framework.

I can't find any reason why no other options show up or any properties I could change. Does anyone know what property could affect this option?

like image 656
Adion Avatar asked Oct 06 '10 09:10

Adion


3 Answers

There could be one of a few reasons for this:

  • Executables located on remote locations (i.e. a server share) cannot be pinned; only local executables can be pinned
  • Certain strings in the shortcut or executable name cause that program to be excluded from pinning. These restricted values are determined by a registry key at HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileAssociation\AddRemoveNames and has these default values: Documentation;Help;Install;More Info;Readme;Read me;Read First;Setup;Support;What's New;Remove
like image 93
JeffFerguson Avatar answered Oct 19 '22 23:10

JeffFerguson


this also has something to do with the location of your EXE as well. my problem was that my EXE was being run from a network location. if i moved it to the local drive then all was right with the world.

like image 39
bnem Avatar answered Oct 20 '22 00:10

bnem


This can sometimes be caused by a "feature" in Windows 7, some filenames are reserved and dont get taskbar status in Windows7, try renaming your .exe file to something else also could you post the name of your .exe?

And if you dont want to rename the file if you browse using the registry to:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileAssociation\AddRemoveNames

You will see a delimited string with the reserved names.

like image 30
kyndigs Avatar answered Oct 19 '22 22:10

kyndigs