Click here to Skip to main content
15,886,199 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
In my WPF application (say MyApp), I have an option where I need to create/modify XML and XAML files. The app is installed in Program Files(x86)\MyAppFolder and location of these xaml/xml files is in a subfolder named "Config" within MyAppFolder. So whenever I try to create or modify xml/xaml files using MyApp and relaunch the MyApp next time I get prompted with the windows installer with a message "Please wait while windows configures MyApp"

Windows installer runs and overwrite my changes back to original. When I installed the application I selected "Everyone" option to install it for all the users. The app is available to all the users but works for the user whom we installed from.

This C#/WPF application requires .NET 4 and I am running Windows 7 home premium.

I am creating the installer using the Setup Project type from the Visual Studio 2010 as follows:-

New Project -> Other Project Types -> Setup and Deployment -> Visual Studio Installer -> Setup Project

Thanks,
SG
Posted
Comments
Sergey Alexandrovich Kryukov 21-Apr-15 21:27pm    
First of all, the sooner you forget this project type, the better. It is discontinued by Microsoft by some very good reasons. The legitimate Microsoft product is open-source (first open-source Microsoft project, by the way) WiX. Not only it is legitimate and compliant with MSBuild standards, it is also much better.
—SA
Smartguy3k 22-Apr-15 3:04am    
I googled WiX and liked it. I am definitely going to try it. Thanks for pointing me in that direction.
By the way meanwhile, I found that as my xml/xaml files are somewhere inside "Program Files(x86)" and there I do not have rights to edit these files and so I should use AppData folders instead for such editable files. So probably that will work.
Regards,
SG
Sergey Alexandrovich Kryukov 22-Apr-15 9:08am    
It all depends on what are those files. XAML could be a part of source code, which is its main use. XAML is translated to programming language and then it's all compiled together. Such files don't go to output at all. (Make sure they don't.)

But XAML could also be used as, say, vector graphics file, which could be created and modified during runtime.

—SA

1 solution

The problem here is the Installer. Use a different installer, Like NSIS, or Inno Setup and you'l not get this type of "error", which is actualy a feature to repair virus infected, and modified/damaged programs.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900