.net-assembly

Error every second time I make a XMLHttpRequest to a php file using dotnet

此生再无相见时 提交于 2019-12-13 05:11:37
问题 I'm trying to get some data from a server using JavaScript and XMLHttpRequest. The PHP file works every time after refresh (F5) if I view it in the browser. The PHP file is calling a function in a DLL using the 'new DOTNET' method. The function is just a simple one returning a string (Message sent from'TestPHP.dll' version 3). If I call the same PHP file using XMLHttpRequest (and javascript) it Always works the first time but not the second time. Every second time I receive an "Error callback

C# Is it possible to get actual type out of a string representing that type? [duplicate]

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-13 04:18:39
问题 This question already has answers here : Type.GetType(“namespace.a.b.ClassName”) returns null (16 answers) C# Getting Type out of a string variable and using it in generic method (3 answers) Closed 10 months ago . I have string "Car", and I would like to get the type Car from it. My class Car is: namespace MySolution.MyProjectA { public class Car { ... } } I trying getting type like this but it returns null: Type myType = Type.GetType("MySolution.MyProjectA.Car"); // returns null Given a

error CS0246: The type or namespace name `CharacterMotor' could not be found. Are you missing an assembly reference?

微笑、不失礼 提交于 2019-12-13 03:23:20
问题 I have script from book (Sams Teach Yourself Unity Game Development in 24 Hours) which I cannot compile its keep trowing me error I add all missing Assembly reference but its still cannot find something. here is assembly from visual studio here is code using UnityEngine; using System.Collections; using UnityEngine.UI; using UnityStandardAssets.Characters.FirstPerson; public class GameControlScript : MonoBehaviour { //The amount of ellapsed time private float time = 0; //Flags that control the

Using custom DataContractResolver with multiple assemblies

限于喜欢 提交于 2019-12-13 02:00:34
问题 I have following setup in a MEF application: Assembly MyBaseAssembly : namespace My.Namespace { [DataContract] public class Container { [DataMember] public Data Item { get; set; } } [DataContract] public class Data { [DataMember] public string Foo { get; set; } } } Assembly SecondAssembly , references the MyBaseAssembly : namespace My.Another.Namespace { [DataContract] public class SecondData : Data { [DataMember] public string Bar { get; set; } } } Somewhere deep inside of my application I

change compiled assembly version information

青春壹個敷衍的年華 提交于 2019-12-13 01:54:04
问题 I have an exe and a bunch of dlls and they are not in strong naming. The exe requires specific version of one of the dlls which has a different version so an error occurs when launching the exe. I don't have the source code for this dll to change its assembly version so is it possible to change this dll's version or its reference within the exe externally? I'd tried "ILMerge.exe Foo.dll /ver:1.2.3.4 /out:Foo2.dll" with the dll, but the resulting dll's version remains the same. Any ideas?

SQL SMO DLL References v12 / v11 could not load

萝らか妹 提交于 2019-12-13 01:51:44
问题 I have created a C# application which referenced various v11 SQL Server SMO assemblies. I've done this by taking copies of these, referencing them with Copy Local=True in the properties of the Reference, and then including them with copies of the application. The application is deployed to 50 or so machines on our company network, some developer PCs, some servers. I started to receive the error Could not load file or assembly 'Microsoft.SqlServer.Management.Sdk.Sfc, Version= 12 .0.0.0,

Could not load file or assembly 'Microsoft.Data.OData, Version=5.6.4.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies

老子叫甜甜 提交于 2019-12-13 01:41:47
问题 I have the error "could not load 'Microsoft.Data.OData, Version=5.6.4.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies." I have all the binding redirects in place to version 5.7.0.0, however at run time the azure instance can not find the Microsoft.Data.OData, Version=5.6.4.0! I was able to RDP to the instance and look with .net reflector, and loading my service dll from azure instance (E:\approot\bin), it seems I have one assemblies depending on this Microsoft

Deserialization with binaryformatter

我只是一个虾纸丫 提交于 2019-12-13 01:13:35
问题 I have a program that serializes an object and sends it over a network: TcpClient client = new TcpClient(); client.ReceiveTimeout = 10000; client.SendTimeout = 10000; IPEndPoint serverEndPoint = new IPEndPoint(IPAddress.Parse("127.0.0.1"), 8888); client.Connect(serverEndPoint); BinaryFormatter binaryformatter = new BinaryFormatter(); NetworkStream networkStream = client.GetStream(); if (networkStream.CanWrite) { binaryformatter.Serialize(networkStream, kort); } And on the other side I receive

How can I find the platform a .NET assembly has been compiled against programmatically?

吃可爱长大的小学妹 提交于 2019-12-12 19:10:45
问题 Looking at the following JetBrains dotPeek view of some given assemblies, how can I programmatically determine the platform such assemblies have been compiled against? I have tried the following method which does not work for assemblies compiled in .NET Core. public static string GetFrameworkVersion(Assembly assembly) { var targetFrameAttribute = assembly.GetCustomAttributes(true) .OfType<TargetFrameworkAttribute>().FirstOrDefault(); if (targetFrameAttribute == null) { return ".NET 2, 3 or 3

When exactly are assemblies loaded?

左心房为你撑大大i 提交于 2019-12-12 16:15:15
问题 So I'm trying to understand exactly when .NET Assemblies are loaded into a .NET process. I read this blog entry which did a great job of explaining things and confirmed a lot of what I thought I already knew, but it also brought up a point in which I think I slightly misunderstood. Dependent Assemblies are just in time loaded when first referenced in code I took this to mean that when and furthermore if the first time a call to an assembly was made then the assembly was loaded into the