ClickOnce: How to change the codebase location in code

  • Thread starter Thread starter Jamey McElveen
  • Start date Start date
J

Jamey McElveen

Sorry I keep posting around tha subject but I cannot get seem what I need
out of clickonce.

another thing that would hele me would be the ability to change the codebase
tag on the server in code at runtime.

lets say on the server I have the following information in my
WindowsApplication1.application file
<deploymentProvider
codebase="http://localhost/task/WindowsApplication1.application" />

I want to write an application that can change it like so without using
mage.exe or mageUI.exe this is the only line I need to change and I wna tto
change it on the fly and on demand to somethig like so.

<deploymentProvider
codebase="http://localhost/task/111111/WindowsApplication1.application" />

I have loaded it into a XmlDocument and changed it but this will not work
because it corrupts the file. It looks as it there is CRC info or something
inbeded in file tho keep people form doing just that for security purposes.

Any help will be GREATY appriciated

Thanks
 
You can modify the codebase however once it changes in anyway from
initial deployment you have to resign the manifests. You have
basically one option here in two flavors. Run Mage.exe or MageUi.exe
and use your key to sign the updated manifests (this basically
acknowledges that the changes you made are valid and not a hack
attempt)
 
Back
Top