cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
msifordummies
Level 3

MSIShortCutProperty Windows 7

Hi. I'm trying to modify the MSIShortcutProperty table so my shortcuts to executables will be grouped and appear under one button on the taskbar. I realize I need the AppID table as well, but the problem I have is the MSIShortcutProperty table. I'm not sure what type of information needs to be entered into the PropertyKey(so) and PropVariantValue. These are the Windows Shell property settings for shortcuts and I'm having trouble entering the appropriate information. The installation keeps returning Warning 1946 error that it cannot set the PropertyKey value. Anyone can provide an example of how to go about doing this?

Ignore the fact that the application itself can be coded to have this Application ID. We have a lot apps which I'm interested in just setting the shortcuts, which I heard can be done.

Thanks.
Labels (1)
0 Kudos
(6) Replies
MichaelU
Level 12 Flexeran
Level 12 Flexeran

What have you tried to put into the MsiShortcutProperty table? It sounds like you're trying to use the System.AppUserModel.ID property, but at this point the best documentation I've seen for this are the blurbs on MSDN (http://msdn.microsoft.com/en-us/library/dd391569(VS.85).aspx and the page it links: http://msdn.microsoft.com/en-us/library/dd378459(VS.85).aspx).
0 Kudos
msifordummies
Level 3

I believe the Installshield AppID correspond to the .NET System.AppUserModel.ID. An application ID (GUID) has been generated where each shortcut can use this GUID as its ID.

For the MSIShortcutProperty table, Installshield asks for

a) Primary key, non-localized token.I entered a string here (ie AppShortcut1).

b) Shortcut leading to the exe which I select from the available drop down list of exe

c) PropertyKey, canoncial string representation of the Property Key being set (which I don't really have a clue as to what this means).

d) A string representation of the value in the property ([FONT="Century Gothic"][/FONT]a again not sure what this is referring to[/FONT]).

I tried entering strings, hex, GUID, integer values for C and D, but the installer fail to set it.

Furthermore, under each component in the Advanced Settings, I created new COM class which allows me to select the AppID GUID I created in the AppID table. Because each component will get a shortcut created, I want Windows Installer to set the shortcut with properties that will enable all the test apps to appear under one button on the taskbar.

The exe were test forms written in C# which does nothing more than just display the form. So I have 4 apps like this for testing if they will appear under one button.
0 Kudos
MichaelU
Level 12 Flexeran
Level 12 Flexeran

What you entered for A and B sounds fine, assuming the value in B matches a first column value for one of the rows in the Shortcut table. C should probably be System.AppUserModel.ID and D should be something like Company.Product.SubProduct.Version or Company.Product.Version as described on the second page I linked; each dot-separated field is substituted with a reasonable value, of course. You will then need a row like this corresponding to each shortcut you want to glom together, which has a new arbitrary key in A, and the next shortcut key in B, but shares the same values for C and D. I've not tried this myself, though, so let me know if it works. 🙂
0 Kudos
Lurean
Level 8

not sure if this will be of any assistance, but it does give an example of doing what it sounds like you are trying to accomplish

http://blogs.msdn.com/windows_installer_team/archive/2009/09/02/windows-7-taskbar-support-with-the-msishortcutproperty-table.aspx
0 Kudos
msifordummies
Level 3

Thanks. The install no longer returns that warning anymore which means it's probably registering it fine now. However, the test apps are still not being grouped to one button.

I noticed the application icon difference between the two test apps. The first app has a blank icon versus a colored filled one for the second. I wonder if that means anything.
0 Kudos
msifordummies
Level 3

Thank you MichaelU and Lurean for all of your help. I was making the changes based on the information both of you provided on my current msi project. I probably messed up a table or two while trying to figure it out, so it did not work.

However, I decided to create a new project, and added the same files back. This time Installshield was complaining about the icon files. I created some dummy icon files and associated with the shortcut. After installation, ...it works!

Thanks for all of your help!

🙂
0 Kudos