.net-assembly

Could not load file or assembly Temporary ASP.NET Files

怎甘沉沦 提交于 2019-12-09 14:29:19
问题 I am developing a aps.net website in C# and I am using framework 4. After creating a new website project I tried to run the project. but I am getting the below error Could not load file or assembly 'file:///C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\myfirst\159977c5\b9e740fc\App_global.asax.yfqtni9g.dll' or one of its dependencies. The system cannot find the file specified. I already went through the below links [and all speaks about access to the folder], but it

The .NET equivalent of static libraries?

自作多情 提交于 2019-12-09 13:15:22
问题 I'm building a tool in managed code (mostly C++/CLI) in two versions, a 'normal user' version and a 'pro' version. The fact that the core code is identical between the two versions has caused me a little trouble as I want to package the resulting tool as a single assembly (DLL) and I don't want to have to include the .cpp files for the common code in the projects of the two versions of the tools. I'd rather have a project for the common code and a project for each version of the tool and have

How to use internal class of another Assembly [duplicate]

非 Y 不嫁゛ 提交于 2019-12-09 06:38:19
问题 This question already has answers here : How can I access an internal class from an external assembly? (5 answers) Closed 5 years ago . I have a third party assembly and I would like to use its Internal class in my new C# project. Is it possible? Any example would really be appreciated 回答1: internal: The type or member can be accessed by any code in the same assembly, but not from another assembly. You can not use internal classes of other assemblies, the point of using internal access

Not allowed to load assembly from network location

戏子无情 提交于 2019-12-09 05:27:49
问题 I've recently set up a new Windows Server 2012 R2 environment and installed Visual Studio 2012 . Now I'm having a problem with multiple .NET 4.5 project's I migrated from my old server, a Windows Server 2008 machine. This never occurred on the old server. When trying to load an assembly from a network location, I run into the following issue: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET

SQLCLR custom aggregate with multiple sql_variant parameters

爷,独闯天下 提交于 2019-12-09 03:46:41
问题 Hy, I have post a question about CLR User-Defined Aggregates few month ago oon this post. This works like a charm. But now I would like to quite the same functions with the two parameters in sql_variant type. Like in my previous post, the two function would be sMax and sMin and will return the first value depending on the second. I found that the sql_variant type is a object type in C#. But I having difficulties to accumulate and compare the object. What is the best option to compare this two

What causes Assembly Version incrementation when using asterisk?

蓝咒 提交于 2019-12-09 02:54:26
问题 If I have an assembly version such as: [assembly: AssemblyVersion("2013.7.18.*")] When this version number is read, it will be something like 2013.7.18.123 . What causes the incrementation of the final number? 回答1: It is not incremented, that would require the build system to know the previous version. It has no such knowledge. You are essentially getting a random number. It isn't that random, the revision number is generated from the time of day. The build number can also be randomized, it

The *deps.json file in .NET Core

☆樱花仙子☆ 提交于 2019-12-08 17:28:21
问题 What is the purpose of *deps.json file in .NET Core? What is the reason to store references in such file and not in assembly manifest(as in standalone .NET Framework)? Using Ildasm i checked that assembly manifest doesn't contain entries for these dependecies after dotnet build command. But it has entries after dotnet publish command. 回答1: The .deps.json file contains metadata about the assemblies referenced by the built assembly and the locations to search for them as well as information

Asp.Net 5: How to load assembly version from project.json file?

こ雲淡風輕ζ 提交于 2019-12-08 16:24:31
问题 I've the project.json file with a version specified as { "version": "1.0.0-*" } How can I read it in code? 回答1: Get the AssemblyInformationalVersionAttribute from the assembly 回答2: in your project.json change the "version": "1.1.xxxx" then in your razor view, maybe _Layout footer? @using System.Reflection @{ ViewData["Version"] = typeof(Startup).GetTypeInfo().Assembly.GetCustomAttribute().InformationalVersion; } then ViewData["Version"] 来源: https://stackoverflow.com/questions/32826684/asp-net

Activator.CreateInstance: Could not load type from assembly

蹲街弑〆低调 提交于 2019-12-08 15:58:06
问题 I'm trying to create an instance of a class implemented in a plugin .dll in my project to do type discovery. I'm receiving this exception: Could not load type 'Action' from assembly 'SquidReports.DataCollector.Plugin.BES, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'. This is the exact method signature I'm using: https://msdn.microsoft.com/en-us/library/d133hta4(v=vs.110).aspx In other words, I'm attempting to spawn the object based on the Assembly name and the class name, like so:

Assembly is being used by another process

点点圈 提交于 2019-12-08 15:28:33
I've upgraded a WCF project running 3.5 vs2008 to .net 4.0 vs2010 and run into a problem. When compiling from vs2010 an assembly in my service implementation project is locked by devenv.exe (note no debugging - only compiling). The assembly is released when vs2010 is restarted and can be compiled once, after each restart. What I've tried to far: Insert PreBuild event to unlock the assembly removed assembly version wild card Disabled source stepping stopped windows search stopped IIS quit vs2010, removed sln.suo and bin/obj folder Read blog and SO posts for 3 days now :) Removed all references