Sunday, June 10, 2007

File Association using Visual Studio 2005 Smart Device Cab Project

I am trying to make an installer for a SVG viewer for Pocket PCs running Windows Mobile using C# and Windows Mobile 6 SDK.
The installer works, but I am trying to make a file association. When I click on a SVG file the application should start and show that file. I've used registry keys like so:

HKEY_CLASSES_ROOT
|
+ .xxx (Default Value) xxxfile
|
+ xxxfile
|
+ DefaultIcon (Default Value) %InstallDir%\MyApp.exe, 0
|
+ Shell
|
+ Open
|
+ Command (Default value) ""%InstallDir%\MyApp.exe"" ""%%1""

but when I open a SVG file I get this error:
" The file 'filename' cannot be opened. Either it is not signed with a trusted certificate, or one of its components cannot be found. If the problem persists, try reinstalling or restoring the file"

If I open the application directly, it works, and the files are shown, so they are not corrupted.

If anyone has an ideea about what could be wrong, please leave a comment or email me.

No comments: