.net-framework-version

WPF Application Errors and .Net Framework Repairs

心已入冬 提交于 2019-12-05 16:35:50
问题 Background : I have a .Net 3.5 WPF "Prism"-based application running on Windows XP and Windows PosReady 2009 PCs. The app runs on PCs that are shut down every night (via a C# call to "shutdown.exe") and booted fresh in the morning (via Wake-on-LAN). The application is touch-based (using ELO touch screens), there are no mice or keyboards attached and the users do not have access to Windows. Issue : We sporadically see issues where one of two things happens; either the application doesn't seem

TeamCity NuGet package build for different .NET Frameworks

╄→гoц情女王★ 提交于 2019-12-05 14:05:44
I've been doing updates to .NET Framework targeted versions of projects updating to latest .NET (4.6.2). Some of these projects are NuGet packages, built in TeamCity 9.0.2. I've use the steps in this guide to create multiple build configurations for different .NET Framework version as some of the projects I haven't updated to 4.6.2 reference the NuGet packages. So I am trying to get TeamCity to use these build configurations to output the various Net40, Net45, Net46 and Net462 versions so that I have full compatibility without forcing the need to upgrade all projects that use the NuGet when

Your project does not reference “.NETFramework,Version=v4.6.2” framework. Add a reference to “.NETFramework,Version=v4.6.2” in the “TargetFrameworks”

风格不统一 提交于 2019-12-05 08:24:19
问题 I can't run my unit tests. I have the next error: Your project does not reference ".NETFramework,Version=v4.6.2" framework. Add a reference to ".NETFramework,Version=v4.6.2" in the "TargetFrameworks" property of your project file and then re-run NuGet restore. In app.config : <startup> <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.2"/> </startup> In Project > Properties > Application > TargetFramework (.NET Framework 4.6.2) How can I fix it? 回答1: Please make the next steps

Can application built with .NET 4.5 run on .NET 4.0?

回眸只為那壹抹淺笑 提交于 2019-12-05 07:31:01
My project is targeting to .NET 4.5. It doesn't use any new 4.5 methods, so it actually works fine on the machine with only .NET 4.0 installed. This is all good until I added some extension methods and reflection. Then when I ran this .NET 4.5 program on the 4.0 machine, it failed with "System.TypeLoadException: Could not load type 'System.Runtime.CompilerServices.ExtensionAttribute' from assembly mscorlib". The famous ExtensionAttribute program that has been documented well here . Another quick way to test this is to add the following line. Then the program will throw the exception when

How can I change a .NET standard library to a .NET framework library?

自古美人都是妖i 提交于 2019-12-04 23:52:47
I'm writing a class library for a simple parser in C#. When I first created it, I used .NET standard 2.0, but now I need to migrate it to .NET 4.6 both to conform to the other projects in my solution and in order to use NUnit. I tried to follow the instructions in the Microsoft documentation , but when I try to select another framework in the properties, I can only find other .NET standard versions. How can I migrate it? Will I need to manually edit the .csproj file? Open up the project file (.csproj) and change the TargetFramework to net462 <PropertyGroup> <TargetFramework>net462<

ERROR: Cannot find all types required by the 'async' modifier. Are you targeting the wrong framework version, or missing a reference to an assembly?

为君一笑 提交于 2019-12-04 17:16:51
问题 I have following configuration of my PC: Windows 8 Visual Studio 2012 .NET Framework 4.5 My Project Configuration is: WP 7.1 Silverlight 4.0 .NET Framework 4.0 CTP ASYNC (installed, using async and await keywords) The project was written using VS2010 on Windows 7 machine for WP7.1. Now I have upgraded the PC to Windows 8 and have installed VS2012. The project, however, complaining about 'async' modifier. Cannot find all types required by the 'async' modifier. Are you targeting the wrong

Copy all dependencies from .Net Standard libraries to .Net Framework Console application

偶尔善良 提交于 2019-12-04 10:59:21
问题 After consuming .net standard projects in a .net framework(4.6) console application, the dependencies of the .net standard projects are not copied into the output directory. This results in run time error of missing dlls. The "copy local" property is already true for the referenced projects. One possible solution is to add all the dependencies again in the console application, but is not a good idea. Is there a better solution to this? 回答1: After going through an article by Scott Hanselman,

Referencing between NetStandard and .Net Framework

风格不统一 提交于 2019-12-04 09:19:34
I'm trying to get .Net Framework and NetStandard assemblies to communicate with each other (to learn what is possible). I currently have four projects, two Framework 4.5.2 projects and two NetStandard1.2 projects: Framework452.Library NetStandard12.CentralLibrary NetStandard12.BaseLibrary Framework452.Tests The referencing structure is: Framework452.Tests references NetStandard12.CentralLibrary : working by adding the NetStandard.Library nuget package to Framework452.Tests . NetStandard12.CentralLibrary references NetStandard12.BaseLibrary : working without modification. NetStandard12

When using .Net Standard 1.4 in a library and .Net framework 4.6.1 in and application, unable to load file System.IO.FileSystem, Version=4.0.1.0

为君一笑 提交于 2019-12-04 08:47:59
I have a solution that contains a library and 2 applications. The applications represent the same program, with one built to target the Windows App Store through UAP10 and the other built to target a Microsoft Windows PC using .Net Framework 4.6.1. I'm using Visual Studio 2017. I set the library project target .Net standard 1.4. I set the UWP application to target Windows 10 Aniversary Edition (10.0; Build 14393), Min version Windows 10 (10.0; Build 10586). I set the generic Windows application to target .Net Framework 4.6.1. The UWP version compiles and runs fine. Initially, the .Net

reference .Net framework 4.5.2 from .Net Core 2.0 project

*爱你&永不变心* 提交于 2019-12-04 03:42:42
问题 I have spent a few hours trying to figure out why .Net Core 2.0 wouldn't load .Net framework 4.5.2 nuget packages. Now I think it's time to ask... What happens is I have a .Net Core 2.0 WebApi app (A) and I want to reuse my .Net framework 4.5.2 library(B). I created nuget packages for B and referenced the nuget package in the A. The libraries are downloaded in the C:\Users\username.nuget\packages folder But when I consume B in the code, it errors me out saying System.IO.FileLoadException: