change clickonce install path - vb.net

I deployed a project via ClickOnce cause I like the update features, but after install on some systems its hard to find.
On windows Vista and Windows 7, you will find the ClickOnce cache here: c:\users\username\AppData\Local\Apps\2.0\obfuscatedfoldername\obfuscatedfoldername
On Windows XP, you will find it here: C:\Documents and Settings\username\LocalSettings\Apps\2.0\obfuscatedfoldername\obfuscatedfoldername
Is it possible to change the path of an application installed via ClickOnce? I've looked in the publish settings and don't see a way to change the default path. Am I missing something?

No, that's beyond the scope of a ClickOnce install.
Why don't you distribute your updates through the ClickOnce system?

Related

ClickOnce default installation path

I inherited a Windows Forms Application (.NET Framework 4) that uses ClickOnce for installation. Everything is working perfectly except I cannot seem to set the default installation path. Currently it gets installed to:
%appdata%\Local\Apps\2.0\xxx
where xxx is some randomly created path. This is causing problems with out virus scanner which is deactivating the program randomly. We cannot exclude the 2.0 directory from scanning as other programs that are not under our control also install to this folder.
I found this online:
https://social.msdn.microsoft.com/Forums/en-US/c6e3d328-1deb-49c9-99cf-98fe3830702a/where-does-clickonce-put-files?forum=winformssetup
where it states that I can set:
System.Deployment.Application.ApplicationDeployment.CurrentDeployment.DataDirectory
to set the data directory -> which might set the program directory as well?
I just cannot seem to find where I can set this path - Any ideas? I have never used ClickOnce before (and am new to Visual Studio) so please give me clear instructions.
Thanking you in advance
see comment:
The data directory is where data files, e.g. MDF and MDB files, get stored. You can't set the install location of a ClickOnce app. They get installed to the ClickOnce cache, which is what makes them ClickOnce apps. – jmcilhinney

Wix Toolset vs. InstallShield - VirtualStore Access

I developed an application with VS2010 and a setup deployment with IS Limited Edition. The application provides some data in a XML file, which is installed in the same folder. If the app was making changes in the XML file, this was saved in virtualStore.
I use now VS2015 and Wix Toolset. The application can be compiled and I was able to code a WXS File. The new built MSI install the app and all seems ok. But now the app cannot access the XML file. The access is denied.
I tried to compare both MSI with Orca, but don't see something noticeable. I'm not sure, if this is a problem of setup or of the application itself.
edit
If I copy the "old" EXE file in the new installation, the application can access the XML file.
Thank you for help and hints
If a program appears to be from before Windows Vista, is running as a limited user, and attempts to write to certain machine-only locations, Windows may redirect its access to the virtual store as part of a backwards compatibility shim. If the program does not appear to be from before Windows Vista, no redirection is performed.
I believe Windows detects whether a program appears to be from before Windows Vista by reading its manifest for supported platforms - the supportedOS elements in the application manifest. My guess is the change in your toolchain from VS 2010 to VS 2015 has resulted in this element being added to your application's manifest (Windows XP is past its supported lifetime and thus Visual Studio 2015 can implicitly assume you are supporting at least Vista).
You may be able to override the manifest, but really you should fix your program to not attempt to write to per-machine locations. Ideally you should use a location such as the LocalAppData folder, although for backwards compatibility there may be benefits to at least reading the old file from the Virtual Store.

Firebreath plugin installation available for all users

i have a problem with the installation of a Firebreath plugin on Windows XP machine.
I'm using Visual Studio 2008 setup project to place generated plugin dll in program folder to get the plugin work but when i run the installer the plugin is usable only by the user who install the plugin and if i log in the machine with another user with limited privileges Firefox cannot see the plugin.
What i'm doing wrong with this process?
Should i use Wix installer instead of Visual studio 2008 setup project to get the plugin work for all users in the machine ?
What is the correct "Firebreath" way to install a plugin and to make it visible to all users in the machine?
Thank for your time!
Francesco.
1) Nothing. This is as designed; FireBreath installs per-user by default, always has. This is a feature, since it means you don't have to have administrator privileges to install.
2) Not by default, no.
3) Uncomment the following line in your PluginConfig.cmake file and rerun the prep script:
# If you want to register per-machine on Windows, uncomment this line
set (FB_ATLREG_MACHINEWIDE 1)

Deploying Winforms Application to Client Machines Application Failing on start

This is Edited from the OP. This is a VB .NET 4.0 WinForms application. There is a mysql datasource involved with this project. The target CPU is set to any. Problem: When running this application on any computer that has VS 2010 installed along with the mysql connector it runs flawlessly. When installing on a virgin system(ie. No developer environment installed) but that machine does have .net framework 4.0 installed and a mysql server without the connector installed the application falls immediately. So to fix the issue I install the mysql connector MSI. This immediately fixes the issue on the client system and it runs. The problems is that as you can see below from my Installer setup that the 2 needed DLL files for MYSQL are actually included in the installation package so should not need to be installed separately. So Why is it that using that installer from the images do I need to install the mysql connector? Any Ideas? Below is a screen shot of the References the program uses and from what I believe I do not need to deploy any of those DLL files with my application other than the 2 MYSQL DLL files. So why is this failing?? Below are images showing the project references as well as the Installer Files that are being installed in the applicaiton folder. As shown in the image the 2 mysql dll files are to be put in the application folder. There is also a screen shot showing each dll's properties for in application folder.
You answered your own question.
but that machine does have .net framework 4.0 installed and a mysql server without the connector installed the application falls immediately.
You don't need to install the connector msi package, but you do need to include the two DLL files in the application's directory. Anytime you have some dependency, you need to deploy it with your application.
Edit solution quoted from my comment:
From your update it sounds like you have a version mismatch on the
assemblies, and the references are set to Specific Version = True.
Check the version number of the assemblies on your developer machine
in the output directory, and check the version you are installing on
the client system. (You can just hover over the DLL to read the
version on the ToolTip). You can try to set Specific Version to false
by right clicking your reference and selecting properties, or simply
ensure you deploy the same version of assemblies. Your program is
looking for the versions its compiled against

FxCop folder missing

What is the issue?
I am trying to install FxCop 10. To install that, Microsoft Windows SDK 7.1 is required. I installed the SDK. Now, to install FxCop, I have to run FxCopSetup.exe, which is supposed to be located in the folder %ProgramFiles%\Microsoft SDKs\Windows\v7.1\Bin\FxCop. But, that folder is missing.
What I did to try to fix it?
I searched the web to fix the issue, and I tried a couple of workarounds that were suggested in a few discussions including (1) not doing a full installation of the SDK and (2) uninstall SDK, reboot, re-install SDK and reboot.
Any help is greatly appreciated. Thanks!
Btw, I'm running Windows 7 (if that's relevant).
In my SDK install, there is an FXCop folder: C:\Program Files\Microsoft SDKs\Windows\v7.0A\FXCop. Is there an FxCop folder somewhere in you SDK install? Apparently it's been moved...
Alternately, I have the FxCop installer on my Dropbox: http://dl.dropbox.com/u/1311259/FxCopSetup-10.0.exe
It's in Program Files, not Program Files(x86). I realized this when running a repair on the windows sdk when I couldn't find the folder, and seeing where it was copying files.
It worked for me when I only selected the "Tools" option to install.