I am trying to publish a WPF application using the publish section in the project properties. When I attempt to specify application files (i.e. references) for the publish, I see lots of old dlls that were once in the project but were deleted later.
Is there a way to clean up this list so that it matches the references actually used in the project ?
It is not possible without extensions. However you can check this question for more details. There are also some extensions listed you could use.
Related
Adding MVVM Light reference to a WPF projects adds a large number of system assemblies to the list of dependencies in the accompanying MSI Setup project. These assemblies (50+ in number) are then copied to the application folder when the app is installed. Why is it so? Why can't it reference it from GAC directly?
Note: Copy Local option is set to True for MVVMLight.dll. I obviously can't set it to False.
Reproducing it is extremely simple. I'm using VS2015 Community.
Create a new WPF Application project.
Add NuGet reference to MVVM Light (or the Lib-only version; doesn't matter).
Add an MSI Setup project to the solution (must have the extension installed).
Add Primary Project Output of WPF application to the setup project.
There you go. A long list of System.X.Y will be added to the list. If you build and install the setup project, you'll see all these DLLs in Program Files folder.
Why? And how to fix it?
Update
The problem does not appear if WPF application targets .NET Framework 4.0 and you add NuGet reference AFTER that. But if you target .NET 4.5, 4.5.1 or 4.6, the long list of dependencies appears again. Think MVVM Light (or NuGet) is having trouble finding the correct package sub-folder.
I don't know why it happens but I can offer a workaround. Just open the project's Detected Dependencies folder, select all of the System dlls, right-click and select Exclude.
Overly agressive dependency scanning is one of the many reasons I don't use Visual Studio Deployment Projects. Instead I use WiX / IsWiX. Both open source and the later written by myself.
For more information see:
http://www.github.com/iswix-llc/iswix-tutorials
I am part of a team of .NET developers and we're trying to use the DNN platform as a way to have a website template so that we will not have to spend weeks or months building core functionality, such as authentication, permissions, navigation, etc. However, I'm very confused as to how the platform works as well as how it's installed. I'v spent many hours researching online at http://www.dnnsoftware.com/ as well as other sites, which only added to my confusion. Here are some specific questions which are still unanswered:
Do we install the source code or not? http://www.dnnsoftware.com/wiki/how-to-install-the-source-package-of-dotnetnuke says that it's not recommended to install source code. On the other hand, http://www.dnnsoftware.com/wiki/packages says that we should use the source code if we are developers (which we are).
If we don't use source code, how do we write code which will be used to add functionality, style, or business logic to our site? Where exactly do we put this code?
I keep on seeing the term "module" being thrown around. What in the world is a module?? Is it a separate .csproj file? Is it a .cs file saved as part of the website? If so, how would we incorporate it without the source code?
Like any other application, we need to be able to maintain full control of builds and deployments. With this, we can see history of what we did, roll back changes if necessary, etc. Currently, for our other projects, we build with TeamCity and deploy with OctopusDeploy. Where does that fit into working with DNN without source? I also know that DNN is set up as a web site project not a web application project (see here http://www.dnnsoftware.com/forums/threadid/338902/scope/posts/threadpage/1) and web site projects is a technology not really being maintained by the newer versions of Visual Studio, and may be harder to deploy as well. Assuming I DON'T want to convert (http://blogs.msdn.com/b/webdev/archive/2009/10/29/converting-a-web-site-project-to-a-web-application-project.aspx), how would I build/deploy the web site project?
http://blogs.msdn.com/b/webdev/archive/2009/10/29/converting-a-web-site-project-to-a-web-application-project.aspx seems to state that it's not recommended to remove dependencies from DNN and replace them with other ones. If that's really true, it makes the whole platform seem very fragile and makes me wonder if I'm using the wrong tool altogether. Was DNN really meant for developers or not? (And if not, what was then intended use?)
Start here->
http://www.christoc.com/Tutorials/All-Tutorials/aid/1
1) Don't touch the DNN source, trust me, it isn't worth the headache
2) You add functionality, override style, etc, through the use of Extension (modules and skins)
3) A separate CSProj (check out my templates http://www.christoc.com/Tutorials/All-Tutorials/aid/2
4) You will deploy by taking the ZIP file from each extension and either uploading through the host/extension page, or taking the ZIp file and putting it into /install/module/ in the root of your deployment target, then have a process call /install/install.aspx?mode=installresources
5) DNN is for sure meant for developers, but it is a framework, build on the framework, don't go in and start jacking the framework itself.
I would start by getting a DNN site running on your local. This is fairly straight forward for any .NET developer.
A module is an extension for the DNN framework that you can essentially (once correctly installed) drop on a DNN page (referred to as tab). All your business logic will go in your own modules and the code for these modules will be the only things that you will have to source control. Do not make core changes to DNN as they will be blown away if you ever upgrade.
You do not need to use Christoc's module template if your module will only need to be deployed once. I find that it brings in a lot of unnecessary components and references that you probably will not need. Create your module's using webUserControls that inherit from DotNetNuke.Entities.Modules.PortalModuleBase. Drop the .ascx file in its own folder under DNN's DesktopModules folder and all required .dll's in DNN's bin folder. In DNN, go to Host>Extensions and create a new extention. To the extension add a module control and add your ascx files as controls (leave your default view's key blank). Other views should have unique keys and you can navigate to them in DNN using EditUrl("KeyName").
Drop your module on a DNN page and go from there.
This is of course an over simplification but it should get you going. There are many tutorials online that I advise you watch to learn the basics like Globals.NavigateUrl() to navigate between tabs and how DNN is put together. This forum topic might assist you http://www.dnnsoftware.com/answers/dnn-7-module-development-step-by-step-tutorial
I am working on a multi-solution project on VS 2013 in C (I must use C for this project). I implemented one "Common" project that I intended to use as a reference in another project. So I have one solution with a common.h and a matching common.c source in which I implemented all the common functions.
I now created a new "Application" project (inside the current one, so I now have 2 solutions) which does many things, and use the functions that are already implemented in the common.c file (that is in the "Common" solution). So I have a app.h file with a matching app.c source. I changed the settings so that the "Application" project will include the "Common" project.
However, when I run the "Application" solution (only it since the "Common" project is only used as a reference without a main function) I receive an error telling me that there is no reference to the functions in common.h.
I looked online for a solution and someone said that I should just copy the common.c to my "Application" project, however this is a very bad solution for me since I want to have multiple applications that all of them use the "Common" project.
How can I solve it?
You shouldn't have to copy any files to make this work. Right-click on your solution at the top of the Solution Explorer window. Choose Add -> Existing Project from the context menu. Find the project file for your "Common" project. It should show up in the list of projects for your solution.
Right-click your "Application" project in the solution explorer and choose "Properties" from the context menu. In the property pages window, go to "Common Properties". Click the "Add New Reference..." button. In the "Add Reference" window, go to the "Solution" tab, and then click the checkbox for your "Common" project. Click "Ok".
Now your "Application" project has a reference to your "Common" project. You can also open common.c and common.h from inside your new solution, and any changes will automatically be applied to all other solutions that reference it, because they are the original files and not mere copies.
The above method assumes that the output of your Common project is a DLL. Visual Studio (for whatever reason) won't automatically copy statically linked library (.lib) files. You can of course link against them, but adding a reference won't work. You will need to go to the properties page for your "Application" project, go to the linker -> input tab, and edit the Additional Dependencies line. You can also add the directory containing common.h to your Additional Include Directories under the C/C++ tab.
Either way, my opinion is that merely copying the files is a bad idea unless you're using modules in source control (e.g. Git modules or SVN externals) to manage dependencies.
I am using VS2010, When you create a new project, you can choose from ConsoleApplication, WindowsFormsApplication, WindowsService, etc. There's also Empty Project.
The empty project contains a reference folder without any references. What is the use of this Empty Project? Is it use for any test?
The “empty project” is used when you wish to create a project that does not have any files or reference automatically added to it.
Sometimes visual studio concept of being helpful is not what you want, and you just wish to be able to define a project to include only what you decide to put in it. This is not directly related to using a project for tests, but may be helpful when you are using a test framework that is not supported by any of the project templates.
I have a Silverlight project with lots of source files. Now I want to create a new WP7 project using the same source code files (but obviously, target WP7).
I link the WP7 project to the existing Silverlight project using Project Linker. However, this does not automatically generate links to the existing files in the source project.
Is there any way using Project Linker to automatically populate the destination project with the already existing files in the source project? Or do I manually have to add links in the WP7 project to all previously existing files in the source project?
I have the same problem, but I resolved it.
Simply exclude all files from "source" project and then re-include them.
In this way project linker refresh its references adding all links!
It worked for me!
I'm not quite sure what you but I think you'll have to do manually in VS.Net, but if all the files in the same directory you can add all the files in one go, it sounds as though you want to select the 'Add as Link' option once the add 'Existing items' dialog is displayed.