Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I am having an requirement to add a project into the existing one. Existing one is MVC 4.0 and using Dot net framework 4.5 application and is using DBML (Linq to SQL classes). The one which I want to add is using EDMX in Dot net Framework 4.0.Edmx is also of lower version. Versioning problem is solved by explicitly defining in Web.Config File. But the thing is both of the projects are building successfully but throwing exception at run time and the exception is ::
Schema specified is not valid. Errors:
App_Code.Model.csdl(3,4) : error 0019: The EntityContainer name must be unique. An EntityContainer with the name 'calendarEntities' is already defined.
and this is coming for every controller where it is being used.
Please help me As I am not clear with how to get rid off this error.
Just because there are specific instances where different versions can be supported, when used incorrectly trying to make mismatched versions of things can lead to what is essentially an unsupported project. This is because mismatched version configurations are not extensively tested and even if you were to call Microsoft support the first thing that they would tell you is to upgrade all of your projects to the same version of the runtime. So that is what I would recommend and if you have a specific issue please post the code and enough of the error so that help can be provided.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
Im having abit of an issue with C# / asp.net website development - i need to have some parts of my site to be handling logic and calculations which i would like to seperate from a compiling word - just like if i had it in PHP i can on the fly edit textfiles and instant have a result, whereas with asp.net i need to get the whole compiler environment up running to change code and restart server etc.
What model could be suggested to pull parts out in something that serverside can be edited on the fly with no visual studio up running ? I was thinking something like python or combined with php maybe ? But not sure how that actually works i would like not to work with this layer through visual studio.
What would be the way on asp.net ?
You can try ASP.NET inline expressions in the .NET Framework
With this, you can build inline code in aspx file, and the code block will be execute during page rendering
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I just got introduced to log4net and its abilities. For starters I'm currently working on a small project. We need to log errors,warnings etc to a file and also send an email to all developers involved about any Fatal errors. Is log4net an overkill for a small project thats got about 10 classes that require the logging functions? Are there any benefits of using log4net in the long run? We were initially going to just use FileIO manipulations and Mail functions to achieve the same.
The answer on this question is primarily opinion-based, some reasons to use a logging framework from the start:
Standard way of logging
Easy configuration
Small projects will grow, if you do it right from the start, there is no later rework needed
Using a logging framework will not cost you more time than writing your own. It will probably safe time. For example log4net will never crash your program when logging fails. Your own framework might interact with your business logic and gives you unexpected results.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
Can i upgrade my existing website from asp.net framework 2.0 to 4.0, is there any harm in doing that? and if i can do that without harming my current website than please tell me the required steps to achieve this target.
thanks in advance.
There are some breaking change if you move to asp.net ver 4
Meaning that you may need to change few things, and evaluate all the pages to see that they still working the same way.
I've always updated my projects through using newer versions of Visual Studio. So for example I'd quite a few projects created in VS 2005 which I then opened in VS2010. VS prompted me to upgrade to the newer .net version and took care of the process for me. Never caused any problems although I stopped it from messing with the web.config etc. which it asks about after doing the conversion.
You should have no big issues except for web.config entries specific to .NET 2.0.
On your application server, you may need to set "Classic mode" insted of "Integrated pipeline" if you experience further issues.
There's no harm in trying. There may be some changes required to your code. Just create a copy of your existing code and attempt to upgrade the copy. Based on that, the decision to go forward with an upgrade is up to you.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
How to share class library for more than two asp.net projects,without duplication.
All projects exist on the same server.
If you install the assembly into the GAC it will be available to any application that wants to reference it.
http://msdn.microsoft.com/en-us/library/dkkx7f79.aspx
Note: This typically isn't how I like to build applications because if you have all of your assemblies in a lib folder then grabbing a copy of the solution from source control gets the developer a solution that will compile without having to go through additional steps like installing separate software.
From within Visual Studio, when you reference an assembly, you can pick the source location, so you can have two separate projects that reference the same DLL with no issues.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I'm an asp.net developer, but I haven't found a good workflow for deployment. Especially for small quick fixes that might not even require compiling.
The way I work now is to have two VS instances up while copy pasting a lot of code and files between the project and the folder on the IIS server. Is there an automated process that moves changes as I save in the VS project?
Generally speaking, what you are doing is a pretty big no no for a lot of reasons.
When you make changes one of the big advantages ASP.Net has over something like PHP is simply that obvious problems (like misspelling a variable name) are caught during the build phase. This is a huge benefit.
Next, if you are simply modifying a file and copying it's content to the server then it sounds like you are doing your testing in production instead of leveraging your local debugger. Again, very bad practice.
Finally, VS includes a publish command. The purpose of this is to compile and publish your site to the server. It can do so through the regular file system, FTP, web deployment packages or even FPSE. That last one is NOT recommended and is probably kept for backwards compatibility only.
Point is, develop and test locally. When your ready for it to go to the server, use the publish command.