assembly-references

Why do ASP.NET resolve assembly references differently?

纵饮孤独 提交于 2019-12-22 05:33:17
问题 I really tried hard to find a similar issue to get some leads, but no one seems to describe the case we are having, so here it goes. Background We have a product with the following general design: [Local installation folder] Contains a set of .NET assemblies, implementing the bulk of our product functionality. Example: Implementation1.dll , Implementation2.dll [GAC] ClientAPI.dll. Our client assembly, to be referenced from end user Visual Studio projects. Has strong references to the

Need Hashtable and Arraylist

旧城冷巷雨未停 提交于 2019-12-22 03:43:14
问题 I am trying to use someone else's C# classes in my Windows 7 Phone app. The classes use objects of type Hashtable. The file in question has using System.Collections; at the top, so I'm assuming that's the Hashtable object it wants. When I try to build my solution, I get errors that the type or namespace name 'Hashtable' could not be found, are you missing a using directive or assembly reference. In Microsoft's documentation of Hashtable, I see it says Assembly: mscorlib But if I try to add

Could not load file or assembly or one of its dependencies. The system cannot find the file specified. (No GAC allowed)

拟墨画扇 提交于 2019-12-20 03:51:37
问题 I have the "Main" program which loads my own "plugin.dll" file dynamically using reflection. The "plugin.dll" file references to the third party "device.dll" by using visual studio references. As long as the "device.dll" and "plugin.dll" are in the same folder as the "Main" program or the "Main" program has the reference to the "plugin.dll" everything works fine. But as soon as I move the "device.dll" file to another folder I get the following error message: "Could not load file or assembly

Why my C# does not have System.ServiceProcess Library?

不羁的心 提交于 2019-12-19 05:08:26
问题 This is the code. I just wanna test the library of System.ServiceProcess library. using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceProcess; namespace ConsoleApplication1 { class Program { static void Main(string[] args) { Console.WriteLine("hi"); var srv = new ServiceController("MyService"); Console.WriteLine("MyService Status {0}", srv.Status); if (srv.Status != ServiceControllerStatus.Running) srv.Start()

Why my C# does not have System.ServiceProcess Library?

删除回忆录丶 提交于 2019-12-19 05:08:01
问题 This is the code. I just wanna test the library of System.ServiceProcess library. using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceProcess; namespace ConsoleApplication1 { class Program { static void Main(string[] args) { Console.WriteLine("hi"); var srv = new ServiceController("MyService"); Console.WriteLine("MyService Status {0}", srv.Status); if (srv.Status != ServiceControllerStatus.Running) srv.Start()

Why is System.Web.Mvc not listed in Add References?

£可爱£侵袭症+ 提交于 2019-12-17 21:54:21
问题 Using C#, Visual Studio 2010. There is a namespace called System.Web.Mvc documented on MSDN. The documentation for all the types in that namespace says that they are in System.Web.Mvc.dll . However, when I go to Add Reference, “.NET” tab, this assembly is missing from the list. Why? 回答1: In VS Express 2012 I couldn't find System.Web.Mvc in the "assemblies" tab, but after a bit of searching I found out that I need to look into " assemblies\extensions " tab rather than the default "assemblies

mvc 4 assembly reference missing for Json.Encode

最后都变了- 提交于 2019-12-17 07:28:54
问题 I am trying to call a Json.Encode(...) method in MVC 4 and I'm getting an error: The name 'Json' does not exist in the current context. I've tried adding System.Runtime.Serialization namespace, which has Json class, but this particular instance of Json class doesn't have Encode method. What assembly am I missing here? Here is my exact code: { url: '@Url.Action("DeleteDefinitionRule")', editData: { companyCode: 'LO', definitionID:@Html.Raw(Json.Encode(Model.DefinitionID)) } } 回答1: References

mvc 4 assembly reference missing for Json.Encode

风流意气都作罢 提交于 2019-12-17 07:28:33
问题 I am trying to call a Json.Encode(...) method in MVC 4 and I'm getting an error: The name 'Json' does not exist in the current context. I've tried adding System.Runtime.Serialization namespace, which has Json class, but this particular instance of Json class doesn't have Encode method. What assembly am I missing here? Here is my exact code: { url: '@Url.Action("DeleteDefinitionRule")', editData: { companyCode: 'LO', definitionID:@Html.Raw(Json.Encode(Model.DefinitionID)) } } 回答1: References

How to check programatically if an assembly reference exists in c#?

…衆ロ難τιáo~ 提交于 2019-12-11 10:38:56
问题 I am trying to write a small c#/.net library for very specific financial calculations. I have written several classes that depend only on the standard assemblies of the .net framework. That is, the library with these classes require nothing other than the .net framework (4.0 client). Now I need an additional class for excel integration. This class will require additional assembly references related with microsoft office and excel, like their respective object libraries. My problem is: Some of

ASP.Net / C# - missing an assembly reference

穿精又带淫゛_ 提交于 2019-12-11 06:37:07
问题 Hi, I am a newbie in C# and visual studio. As Figure1 shown, I am trying to use the classes from other project in similar solution. For example: I try to write "Using LibraryMS.Framework" at UserDto.cs from "LibraryMS.MasterSetup". And I get the following error message: "the type or namespace name 'framework' does not exist in the namespace 'LibraryMS' (are you missing an assembly reference?)" Does anyone know how can I solve this? Also, do you have any good ASP.net website development online