问题
I'm trying to install a XAP file offline using sllauncher but it is not working.
UPDATE I erased all the existing references and folders for my app and now it seems to be working. I will leave this up as it has some good clues on how to solve this. C:\Documents and Settings\Rod\Local Settings\Application Data\Microsoft\Silverlight\OutOfBrowser\index
I made a bat file with the following:
"%ProgramFiles%\Microsoft Silverlight\sllauncher.exe" /install:"c:\TourneyManager.xap" /origin:"http://www.pokerdiy.com/Portals/6/TourneyManager/TourneyManager.xap" /shortcut:desktop+startmenu /overwrite
I have put the xap file in the same folder as sllauncher, the bat file and now trying my c: root but no joy. It just runs with no error message and nothing in the event log. It is definitely executing sllauncher as I can change a param and generate an error.
If I install the app from the website OOB then run the uninstaller it does uninstall it:
"%ProgramFiles%\Microsoft Silverlight\sllauncher.exe" /uninstall /origin:"http://www.pokerdiy.com/Portals/6/TourneyManager/TourneyManager.xap"
My research: After I install it from the website, the shortcut (which works fine OOB) points at this:
"C:\Program Files\Microsoft Silverlight\sllauncher.exe" 1851630633.www.pokerdiy.com
I then looked up
C:\Documents and Settings\Rod\Local Settings\Application Data\Microsoft\Silverlight\OutOfBrowser\index
and there is a file www.pokerdiy.com which points to the Application ID and fully qualified origin:
1851630633 http://www.pokerdiy.com/Portals/6/TourneyManager/TourneyManager.xap
When I run my bat file offline it creates an applicationID and adds the correct origin to the index file, however, there is no xap file in the folder it creates and no shortcut to run it. I assume it is not finding the xap file for some reason.
Does it matter if the XAP is in release or debug mode? I would not have thought so...
Any suggestions please?
回答1:
I managed to get this working - I am not entirely sure how but I started by erasing the existing references installed folders here:
C:\Documents and Settings\Rod\Local Settings\Application Data\Microsoft\Silverlight\OutOfBrowser\index
It seems a little flaky (at one point the install worked but the app just showed a white screen) - but start by looking at the file in the index folder above to see if your xap is being copied to the correct folder.
I will leave this up as it has some good clues on how to solve this.
来源:https://stackoverflow.com/questions/3697544/installing-silverlight-4-app-with-sllauncher-does-not-work