I am looking for a solution to:
I don't have authorisation for installing an application on a client computer. That's why I need to deploy the application without an installer. Just like a portable application or a standalone application - something like that.
The client computer also has a limitation in its Internet connection, so ClickOnce will not work either.
I'm using Visual Studio Express 2010. I saw WiX could solve my limitation in setting-up my application. But still, I can't install the application.
In your solution, set CopyLocal to true for all projects. This will ensure that the ..\Bin folder contains all the necessary assemblies for your program. Then just zip up the ..\Bin folder, get it onto the client machine, and then unzip it.
Related
I created a new WPF project. I copied the built .exe file onto another computer and tried to run the application. But nothing happened. It was just loading. Nothing more.
All my WPF projects do this thing.
What am I doing wrong? Has anyone any idea?
Edit: For somebody in the future: the question might not be clear. What I meant was that I created a simple WPF application with nothing in it and tried to run the application on another computer. I wasn't able to make it run. Just nothing appeared. I figured out that the Avast Free Antivirus was causing this problem. When the antivirus is turned off, it runs as expected. Even though it is no solution, at least we know, what was causing the problem.
You are probably missing the dot net libraries on the target machine.
For quick fix, download the dot net framework distributable for the .net version you compiled against and install it on the target machine. Here is 4.5.1 for example.
For actual distribution, look at creating an installer that will ensure all dependencies are installed with the application. InstallShield has a limited edition which may be included with your edition of visual studio
Try publishing your application using click once. You can do this by right clicking on your project > Publish > Specify the location to publish your application > Finish. Copy the files inside the Published folder to another computer and try installing by click the setup.
Note: The instructions I said above only works if you only have basic functions on your app. If your application uses SQL Server, you need to install it first on the computer that you will be installing your application in.
For your reference. How to: Publish a ClickOnce Application using the Publish Wizard
My C# code loads a C++ DLL. It works fine on my PC, where Visual Studio 2008 is installed. But on other machines the program stop with an exception
Unhandeled exception: system.dllnotfoundexception unable to load dll ...
this application has failed becasue the application configuration is incorrect....
How can I make this code run on a machine that doesn't have VS 2008 installed?
You must distribute your DLL along with your project if it is a custom DLL of yours. If not, you must install the required DLL either with a custom installer or if it is from a different provider, a installer of them.
This post might be a bit older, but
DLL Files And .NET ClickOnce Deployment
I want to deploy one of my .NET apps as a ClickOnce application. The issue is that I am connecting to Oracle (see previous posts here and here). Connecting to Oracle requires at least, 4 DLL files that generally have to be in the same directory as the EXE file. The issue is that when the program is published, the DLLs are not referenced in any way, so the program won’t work.
Then I read about adding the files to the project, so that ClickOnce and the Publish processor will figure out that the DLLs are required and add them to the manifest.
Here is the process in Visual Studio 2005:
1. Put the 4 DLL files in their own directory in your solution directory (for ease of use mostly).
2. Add all four files to your project by going to “Project->Add Existing Item…”
3. Click on each DLL file in the solution explorer and then change their property: “Copy To Output Directory” to “Copy Always”.
That’s it! Now when I publish or even run the application I don’t have to worry about if the DLL files are where they should be.
in vs 2008 on project:
Properties>c/c++ >Runtime Library > choose: Multi-threaded Debug (/MTd)
This is my first windows application. I have published my project and here are few questions.
Now I have two files - a Setup.exe file and a ClickOnce Application Deployment Manifest file. However both install my application in the machine. What is the right file I should be relying on while installing at the client's place? What is the difference between these two?
Should my application be installed at each client machine? Or would it work if I install my application in the server and try to access the shortcut from a client machine (through LAN)? Would it work? If it is running over LAN, should the client machine have .NET framework installed?
Any input is highly appreciated.
See your question contains some answers.
Ans 1. Setup.exe and ClickOnce Application Deployment Manifest file both will install your application but when u run setup.exe it will install all requirements that your app require.
Lets say your app uses .Net Framework 4.0 and Crystal Reports. Then in the setup project(i hope u r using Setup and deployment project of Visual Studio) rightclick on project and click on properties
Then click on prerequisites... It will show u list of prerequisites available. Check on .Net Framework 4.0 and Crystal Reports and compile your project.
Now when u run setup.exe it will first search for .Net 4.0 Framework and crystal report. If not found it will install them and then proceed for your software installation
OR
if already installed then will directly jump for your software installation.
This will not happen if you directly install your software from ClickOnce Application Deployment Manifest file.
Ans 2. U have to install your software on each client for if there is not framework. it will not run your app.
If you are deploying using ClickOnce you will be installing it on each client machine (this is fine) and the relevant .NET framework(s) installed on each client - these can be installed as a pre-requisite of the application install by configuring the ClickOnce settings.
For ClickOnce the main setup file is setup.exe but it relies on the other files in the deploy package, so asking which specific file is most important isn't really relevant.
If there is a reason you don't want to install the application on each client then you may want to look into developing an IIS (web) application or using a product like Citrix to enable access to the application from the server.
i have a same type of windows application.
currently this application is in use.
if you don't want to install with client PC now you do not have to create the windows application you have to create web application because in windows application you have to install your setup.exe in each client PC.You can not access windows application without install in client PC.
I am using Microsoft.Smartdevice.Connectivity assembly as a part of a larger application. Now I have to deploy that application and I can't find any info in regarding to deploying such applications. Even on the msdn resource page there is a question regarding this issue, with no replys.
So how can I deploy such an application. Is there a list of assemblys I have to deploy or something?
I have included the Misrosoft.Smartdevice.Connectivity.dll however the application is still missing at least one file: "Microsoft.VisualStudio.Connectivity.Interop.dll" I can't find that file anywhere. How can I deploy this application on a machine without visual studio installed.
How can I deploy the application on a computer without visual studio? Is there a SmartDevice Connectivity API redistributable or something?
Thank you for your help.
There is a tool called IsoStoreSpy.application. You can use it to deploy applications.
Good luck
This is a very old question but these libraries are in the NuGet package managerment framework which should allow you to include references. Set the project's build to copy all package-managed DLLs into the output directory of your executable.
http://www.nuget.org/packages/Smartdevice.Connectivity/
I have developed a C# windows form application.
How should i create an .exe file in Visual Studio 2008 so that it can be installed in other machines?
A Simple "Setup and Deployment" project would work for most cases. WiX if you want to learn a powerful installer, or any of the other OSS installers out there. You could even zip up your release dir if that is all you needed and didn't want the app in the start menu or any such thing. Your question is somewhat vague.
I suggest you take a look at ClickOnce deployment. There's a video here: http://windowsclient.net/learn/video.aspx?v=14105
If you just want the .exe file, it is located in the bin\debug or bin\release folder of your project's directory depending on the current configuration setting.
My advice would be to use ClickOnce technology to deploy your application. There are details in this previous question. But here is an excerpt:
Directly from the words of MS, ClickOnce overcomes three issues in deployment:
Difficulties in updating
applications. With Microsoft Windows
Installer deployment, whenever an
application is updated, the user must
reinstall the entire application;
with ClickOnce deployment, you can
provide updates automatically. Only
those portions of the application
that have changed are downloaded,
then the full, updated application is
reinstalled from a new side-by-side
folder.
Impact to the user's computer. With
Windows Installer deployment,
applications often rely on shared
components, with the potential for
versioning conflicts; with ClickOnce
deployment, each application is
self-contained and cannot interfere
with other applications.
Security permissions. Windows
Installer deployment requires
administrative permissions and allows
only limited user installation;
ClickOnce deployment allows
non-administrative users to install
and grants only those Code Access
Security permissions necessary for
the application.