The .NET Framework is a software framework for Microsoft Windows operating systems. It includes an implementation of the Base Class Library, Common Language Runtime, and Dynamic Language Runtime. It supports many programming languages, including C#, VB.NET, F# and C++.

learn more… | top users | synonyms

0
votes
0answers
47 views

Why Moles (shims) frameworks are very less [on hold]

With consideration of difference between Mocks and Moles, as they say: "The MS fakes framework supplies stubs and moles (shims), whereas NMock, RhinoMocks, and Moq all provide stubs and mocks......MS ...
6
votes
2answers
1k views

Why isn't anyone talking about parallel compilation for .Net?

Builds are slow and take time. We can get MSBuild to parallelize them, but only on a single machine, not across a cluster. Why hasn't anyone come up with clustered build solutions in the .Net space? I ...
0
votes
1answer
61 views

Tracing and Logging per item instead of per application

I'm building a service in .NET that process "things" in the background and I'd like to trace the execution of these things per item, not per application. Most logging frameworks (I'm familiar with ...
-1
votes
0answers
8 views

Using linq to query a collection, gouping and summing certain items [migrated]

For some reason I cannot get the correct vb.net syntax (visual studio 2010) for a Linq statement that will do the following. Simplest and most straight forward code would be appreciated. Here is the ...
-4
votes
0answers
46 views

Mock interview help in Oslo Norway [closed]

I am basically from India but I have moved to Norway a year ago. I am looking for a job here as a .net developer. The most basic requirement is Fluent Norwegian. I can communicate very well in ...
1
vote
2answers
101 views

Separate methods or single method with if statement?

I'm working on a .NET application and I'm wondering if I should use separate methods to handle the click events of two different buttons. They essentially do the same thing, just on different objects ...
1
vote
1answer
71 views

More than 20 Records Inserted in a Span of 1 Sec

Well, this is not specific to any programming languages. I came across this situation in Android, iOS, PHP and .NET. The problem is many times I come across a situation while building IoT apps, where ...
3
votes
3answers
246 views

ASP.NET MVC should I reference the DAL from the UI?

I am developing an ASP.NET MVC application, and I have three projects: UI (with the system.web.mvc reference, BL and DAL references) BL (business facade and business objects) DAL (contains my ...
-1
votes
2answers
80 views

Productivity using .Net WPF for large ERP (LOB) desktop applicatons ~1500 forms\dialogs [closed]

I am wondering if WPF will fit in my case: We want to refactor an old legacy application written in a 4GL language with about 1500 forms\dialogs. We want to do that in .Net (desktop application), now ...
0
votes
1answer
187 views

Using Statement lambda in exception handling

Following is a code snippet from MVP Win Forms application and this explanation would be helpful when answering the questions. My DAL doesn't handle exceptions and it will be propagated up to the ...
1
vote
1answer
187 views

Clarification about Event Producer in StreamInsight

I need a small clarification about StreamInsight, I know by doc's that StreamInsight can handle multiple concurrent Events. But will the event producer be a separate function, for ex: I need to watch ...
33
votes
8answers
10k views

Return magic value, throw exception or return false on failure?

I sometimes end up having to write a method or property for a class library for which it is not exceptional to have no real answer, but a failure. Something cannot be determined, is not available, not ...
4
votes
3answers
2k views

Is the ADO.net Entity Framework appropriate when all you do is insert records in bulk?

My department develops software to migrate databases for our customers from their old CRM software to ours. In this process we could be inserting up do millions of rows, processed one at a time as we ...
1
vote
2answers
377 views

Repository Pattern: Doctrine2 vs Microsoft Entity Framework?

I have been using Symfony2 with Doctrine2 for some years. I have recently started using Microsoft's Entity Framework with MVC5. From my Symfony2 experience I understand that a repository's job is only ...
2
votes
1answer
258 views

Why does SortedDictionary not implement IReadOnlyDictionary?

The .NET type SortedDictionary<TKey, TValue> does not implement the interface IReadOnlyDictionary<TKey, TValue>, although Dictionary<TKey, TValue> does. It is trivial to make ...
2
votes
2answers
168 views

Separation of retrieving data and business objects between DAL and BLL Layers

I did some research before posting this question. Among other questions or post, one of those is provided below. I could not get a clear mind how to determine.. Business Objects within a Data Access ...
0
votes
1answer
133 views

How do we isolate dependencies for a .Net app deploy in a way which is safe for a strongly-named assemblies?

To design in such that it is easy to deploy dependencies with your app, and so that development environments are easy to set up, it is advantageous to isolate an app's dependencies from it's ...
1
vote
1answer
126 views

Best approach for a server configuration data collection and reporting solution from a legacy script?

I have a project which involves collecting config data from windows servers in our (very large) server estate. My manager wants me to collect over 150 data items across all configuration areas ...
2
votes
1answer
174 views

how to process document state transition?

Imagine there is an application (ASP.NET MVC) that processes some documents. The document must be revised several times by different group of users. state/role rules: simple user can only publish ...
0
votes
2answers
370 views

can you have too many dto/bo - mapping method

I have a windows service, 2 web services and a web interface that need to follow the same path (data wise). So I came up with two ways of creating my solution. My concern is the fact that the ...
2
votes
1answer
66 views

Under which circumstances does it make sense to lose track of where an exception was thrown from?

Is there any valid reason why a catch block on a lower layer would throw back an exception caused by a higher, unknown layer using the following syntax: throw ex; ... rather than: throw; ... ? ...
0
votes
1answer
48 views

Advice needed on rethrowing an exception

Consider the following c# code: public class ExceptionManager { public static void TreatException(Exception ex) { if (ShowAndContinue(ex)) // display a user-friendly ...
1
vote
1answer
85 views

What is the best and most optimized way to return a filestream from a .NET WCF SOAP service?

To give some background, i have a WCF SOAP service in .NET that needs to return pdf files. This service will be used by multiple application, many times in a day. The size of the files returned varies ...
0
votes
1answer
238 views

Speech Recognition in the .NET framework is not efficient [closed]

I want to create a Virtual Keyboard that can catch whatever key you 'speak' and send the keystroke to the active application. The Virtual Keyboard part and linking it to Speech Recognition will be ...
0
votes
2answers
381 views

Organizing solution / project structure and classes for Line of Business Application (LOB)

The question how-do-you-organize-your-projects already has a few good answers. I would like to get a better understanding about this suggested structure: MyApp.Core MyApp.Model MyApp.Presenter ...
2
votes
3answers
67 views

Pre-processor usage to separate logic to different versions of product

In the .NET code base of a product, there are #if pre-processor statements to define whether certain functionality should be available. Like so: shared logic #if version1 some logic #endif #if ...
2
votes
3answers
107 views

Reliable secure data exchange between service written on .NET and an iOS client app

I have a service written on .NET working on a company server. It designed to do a very simple thing, to receive a request via WCF named pipes from another service working locally on the same server, ...
3
votes
1answer
199 views

The most effective arguments in favor of improving code quality, for a manager [closed]

My employer's legacy system started off (in 1997) as very structured procedural code (with a smidgeon of OO), and it was luckily one of the 10% of software projects that was successful. It may look a ...
18
votes
1answer
2k views

Async network programming using Reactive Extensions

After doing some (more-or-less) "low-level" async socket programming years ago (in an Event-based Asynchronous Pattern (EAP) fashion) and recently moving "up" to a TcpListener (Asynchronous ...
1
vote
7answers
378 views

What is the simplest way to broadcast data from application to other applications in .Net

I want to send information from one .Net application to multiple other .Net applications. I want the applications to be loosely coupled. The number of applications receiving the information could ...
18
votes
10answers
845 views

Is it reasonable to assume/require the .NET framework these days?

Background: I have a project where I need to provide the user a download package with some sensitive data in it. The data needs to be encrypted. After they download it, they need to be able to view ...
1
vote
1answer
67 views

Why does a custom action filter need to inherit from both ActionFilterAttribute and IActionFilter?

I m first time creating a custom action filter and following this link http://www.asp.net/mvc/overview/older-versions/hands-on-labs/aspnet-mvc-4-custom-action-filters They are saying to Extend ...
1
vote
1answer
134 views

Should one write a custom IndexOutOfRange exception?

In the process of writing a special collection I utilized the already exisiting IndexOutOfRangeException as e.g. a list or array would throw if I were to access an illegal index. Code analysis tells ...
3
votes
3answers
223 views

Interface to enumerate over files

I'm trying to design a generic interface for enumerating over a list files. Each iteration will open a file, allow the consuming code to access the file to perform some task, and then close the file. ...
1
vote
0answers
100 views

Callback pattern handling exceptions - Best practices in .NET 3.5

I am looking to implement the callback pattern with error handling such that error is caught and pass to the callback code with the response. Since I am using .NET 3.5, I cant use Task (TAP) pattern ...
2
votes
3answers
209 views

Is this extension method any better than just casting to an int?

The following extension method was set up in some code I maintain. public static Int32 GetInt32(this System.Data.Common.DbDataReader reader, string name) { return ...
2
votes
3answers
125 views

.NET Framework standard container type for multi-value property?

I'd like to create a simple class property which can contain multiple values set from the outside. (Values are of the same type.) Example of property name and contained items: KnownHidScanners ...
2
votes
2answers
376 views

What is an alternative to bitwise flags?

I was trying to be smart and elegant, and I ended up shooting myself in the foot by coding my entire application to use flags to store various combinations of settings. Now, I have hit a point where ...
-4
votes
1answer
58 views

How do i upload small changes on a view of an asp.net mvc4 project [closed]

How do i structure an asp.net mvc 4 website in such a way that i can make small changes to views and upload those small changes only. i am a php developer trying to switch to asp.net mvc4. please ...
8
votes
4answers
805 views

Acceptable placement of the composition root using dependency injection (DI) and inversion of control (IoC) containers

I've read in several sources including Mark Seemann's 'Ploeh' blog about how the appropriate placement of the composition root of an IoC container is as close as possible to the entry point of an ...
3
votes
1answer
232 views

why Web API 2 has RouteConfig.cs file?

I m working on Web API project, and it is using WebApiConfig.cs file to defined routs for Web API. Web API fold RouteConfig.cs file. I have googled and they say RouteConfig.cs is for MVC routing. It ...
4
votes
1answer
562 views

Blurring the lines between async and regular functions in C# 5.0

Lately I can't seem to get enough of the amazing async-await pattern of C# 5.0. Where have you been all my life? I'm absolutely thrilled with the simple syntax, but I'm having one small difficulty. ...
0
votes
1answer
39 views

Updating ip address for custom domain [closed]

I'm looking to transfer the ipaddress for my site from one ip address to another. Reading through the Register.com documentation it says that it may take awhile for the DNS changes to ...
1
vote
1answer
286 views

Implementing a tricky REST API with ASP.NET Web API

I'm trying to build a RESTful API using ASP.NET Web API for a game, and here are the methods I have so far: /games GET /games/:id GET /games POST /games PUT /games DELETE /users GET /users/:id GET ...
2
votes
1answer
188 views

In a generic method, what exception should I throw when a type parameter is unacceptable?

When the value of a normal parameter is unacceptable (and the requirements can't be checked completely at compile time), we check at runtime and throw an ArgumentException if the check fails. When ...
0
votes
2answers
290 views

What's the advantage of auto-property initializers without primary constructors?

In this chart about the features that are in or out of the next version of Roslyn (specifically, for C#), primary constructors are out, but auto-property initializers are in. The best use case I've ...
1
vote
1answer
75 views

How can I share a managed DBConnection across various objects?

I am implementing what I thought was a simple object wrapper around a database where one object "PartRecord" represents one row of a database table. I want a client to be able to request a given ...
0
votes
1answer
152 views

Best practise to versioning Web Service WCF

I've a web service SOAP developed with WCF, there is a best practise to versioning it? when I change the contract I don't want to update all the client's referiments but I want simply publish a new ...
1
vote
1answer
270 views

Exceptions: What to handle, what to throw

I have a custom configuration reader which performs various functions on top of .NET's CloudConfigurationManager and ConfigurationManager implementations, such as caching, type conversion, etc. The ...
-1
votes
1answer
104 views

HTML and CSS required for .NET Development [closed]

On a job application, part of the job description is "...needs to know HTML and CSS as some .NET is required...". What does this mean? I thought HTML is a programming language, CSS is a way to ...