.net-assembly

Assembly is being used by another process

回眸只為那壹抹淺笑 提交于 2019-12-08 06:02:00
问题 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

“Could not load file or assembly” error but I don't know which project is referencing this assembly with old number

为君一笑 提交于 2019-12-08 05:38:00
问题 When I am launching my WPF application, I got the error "Could not load file or assembly 'ASSEMBLY_NAME, Version=0.4010.4609.26378, Culture=neutral, PublicKeyToken='XXX' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)". The ASSEMBLY_NAME is the name of one project, which is referenced by many other projects because it is a core. My WPF project is also referencing it, and some projects

How do you tell which dll your c# application is using?

戏子无情 提交于 2019-12-08 03:56:08
问题 I have an application which uses a .dll which is full of gui application code in location x. It use to have 1 button in, but now has 2. When i start my application what i expect to see is a gui with 2 buttons, however i see a gui with 1 button. i have rebuild my gui .dll but it is magically using an older version from somewhere. If i try and debug my code it says that the version of code i am using is different from the one in the .dll My question is, "How can i find out where it is looking

How to load an internal class in end-user compiled code ? (advanced)

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-08 03:40:27
问题 I have a main program with two classes 1- A winform that contains two elements : Memo Edit to type some code; Button named compile. The end user may type some VB.Net code in the memo edit and then compile it. 2 - A simple test class : Code : Public Class ClassTest Public Sub New() MsgBox("coucou") End Sub End Class Now I would like to use the class ClassTest in the code that will be typed in the MemoEdit and then compile it : When hitting compile I recieve the error : The reason is that, the

How to redirect an assembly binding for a DLL irrelevant of the loading host

↘锁芯ラ 提交于 2019-12-08 03:23:42
问题 I have a DLL that uses assembly binding via it's .config: <?xml version="1.0" encoding="utf-8"?> <configuration> <runtime> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <dependentAssembly> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" /> <bindingRedirect oldVersion="0.0.0.0-9.0.0.0" newVersion="9.0.0.0" /> </dependentAssembly> </assemblyBinding> </runtime> </configuration> This is needed because the dependencies load conflicting

Dynamically load dll from android_assets folder

寵の児 提交于 2019-12-08 03:09:26
is it possible to load an dll with Assembly.Load when it's in the asset folder? I have platform specific dll's for windows and android. I tried to use the android specific dll as asset (also in the build action), but when I try to load it into my app it's not found (I used the path: file:///android_asset/mydll.dll ), and this only happens, if i build the app as release, in debug i get the necessary paths to load the library, but not from the assets folder. What can I do? Is there another place, where I can put my dll to be loaded from my app? Mike Stonis Here is an example of writing out

Reference Assemblies folder and different assemblies with the same version

依然范特西╮ 提交于 2019-12-08 02:49:41
问题 I have a project that uses System.Runtime.Serialization assembly. I am using the type DataContractSerializer from that assembly, but I have a problem. There are two assemblies: C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.0\System.Runtime.Serialization.dll C:\Windows\Microsoft.net\Framework\v4.0.30319\System.Runtime.Serialization.dll Both of them have the same version - v4.0.30319. The first one have 429kb size, and the second one 1037kb. I used reflector to

Unknown build error, 'Could not load file or assembly 'System.Windows

℡╲_俬逩灬. 提交于 2019-12-08 00:21:42
问题 I am trying to build a test project for silverlight application. When i build this project it throws following error Unknown build error, 'Could not load file or assembly 'System.Windows, Version=5.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)' I have system.winwos dll in my references and i am using visual studio 2012. What should i do

Could not load file or assembly 'Microsoft.Office.Interop.Excel'

隐身守侯 提交于 2019-12-07 20:14:57
问题 I'm having a problem using Excel in my WinForm application. When I try it on several computers it works just fine on them, but when I try it on another computer it gives me the 'System.IO.FileLoadException: Could not load file or assembly' error. I've added a reference in my project ('Microsoft.Office.Interop.Excel') and even set 'Copy Local' to true. I don't know why this is happening because all computers use the same office version(Office 2007 = Version 12). Anyone has an idea? thanks, Udi

User.Identity.Name - which assembly reference brings that into your project?

那年仲夏 提交于 2019-12-07 19:49:38
问题 I can't find out which reference assembly the User.Identity.Name comes from. How do I find that out? I need to add it to a class library rather than the default MVC 5 app I have made so that I can have access to it? http://msdn.microsoft.com/en-us/library/system.web.httpcontext.user(v=vs.110).aspx C# Class Library / AUser.cs public class AUser { public string Username { get { return User.Identity.Name // doesn't notice User } } } 回答1: Appears to be in the System.Web namespace. http://msdn