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
3answers
67 views

How to restrict the violation of an N-Tier Architecture

Recently we fitted a 4-Tier Architecture in our project composed by the following four main layers : User Interface Layer. Data Access Layer. Domain Layer. Business Layer. All the layers fulfill ...
2
votes
0answers
36 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 ...
1
vote
1answer
78 views

alternate approach of binary serialization/de-serialization

Is it possible to convert a list of object directly to byte[] (and vice versa) to gain performance (by avoiding serialization/de-serialization)? What I have in mind is that a list is somewhere in ...
0
votes
1answer
39 views

Flexible authorization design in ASP.NET pages?

I'm developing an ASP.NET webforms application with pages which displays information based on the authorization level of the authenticated user (very typical). I will write a simple example of the ...
0
votes
1answer
47 views

Modifying XML documents using deserialization/serialization VS LINQtoXML and XPATH [closed]

I have XML documents that I need to modify, I also have the XSD schema that defines their structure. What I did was this using XSD.exe tool I create class object from the schema in program ...
0
votes
0answers
75 views

Are your code-first classes your domain classes? [closed]

When using Entity Framework does anyone else make a distinction between their code-first data classes (used to generate their DB) and their domain classes? If you don't, how do you reconcile the ...
0
votes
2answers
91 views

Testing C# Eventhandler Subscription

I want my unit tests to be able to verify that some events were subscribed or unsubscribed at specific points. Currently, I see two options. VerifiableEventHandler Each client subscribes using the ...
0
votes
0answers
41 views

Converting printable documents to TIFF in .NET [closed]

I have been handed a requirement to convert a series of files into TIFF format as they come into my application. The requirement states that these files may originally be in any printable format ...
0
votes
1answer
170 views

The problem of dependencies management

Let's consider the next situation: We have a module A which has a class Crt570 intended to interact with a device. We have a module B which uses Crt570 in the class called M100Communicator. We have ...
0
votes
1answer
66 views

A specific problem with architecturing a part of our application

Firstly, I'll try to describe the real world model of what we are trying to express in C# code. We have a device called M100. It's purpose is to read\write data from\into cards (plastic or ULTRALIGHT ...
0
votes
0answers
20 views

Executing user configuration settings

For an API I'm building what it does is load an XML file that is passed to it as a string, drill to the correct element, modify values, and return the modified XML. I'm doing something like this in ...
1
vote
2answers
152 views

Environment-aware Code

There are situations where the deployed environment (development, test, or production, for example) might dictate the outcome of certain actions. For example, perhaps a successful "user registration" ...
2
votes
2answers
130 views

Refactoring sought for replacing shared data types in .NET component

I am in charge with updating a software product that is made up of two components the Controller process and the UI process. The Controller and the UI communicate via XML messages. Furthermore, the ...
1
vote
1answer
174 views

Does the recent open sourcing of MSFT's C# compiler mean it can be made cross-platform? [closed]

I really enjoy working with C# however one of its biggest drawbacks is that it is kind of split-brained between MSFT .NET and Mono. In practice its not a big deal most of the time but it is one of ...
1
vote
1answer
122 views

Why no MVC methodology for desktop applications? [closed]

I'm currently learning how to develop web apps with C#, ASP, .NET and MVC. I am enjoying the MVC paradigm a lot, but then thought about using this to develop desktop software with. I googled around, ...
1
vote
1answer
73 views

Does WinRt have support for .Net Framework and Wpf? [closed]

I want to find out if WinRt does or not support .Net Framework? WinRt does or not support WPF? Our company has developed applications using WinForms and they want to have them also running on ...
2
votes
3answers
157 views

Best Practices - separation of concerns and inheritance issues

Here's the situation: I have a "common" Data Access assembly that contains classes used in all my projects. Some of those are abstract classes that are only implemented by my data access layers for ...
4
votes
5answers
860 views

Why do projects opt to stay on an older version of the .NET Framework? [closed]

Why do projects opt to stay on an older framework version of the .NET Framework? For example, staying on .NET Framework version 3.5 which was released in 2007 instead of upgrading to the latest 4.5.1 ...
0
votes
2answers
91 views

Why separate unit tests into an assembly [closed]

I primarily develop in .Net, and have been playing around with F#. It's a nice concise language, but I'm just using it for throwaway code currently. I've taken to sitting my tests in the same file as ...
0
votes
1answer
100 views

Domain driven design and WCF services architecture

I am trying to figure out how to architecture my project in the DDD paradigm (a complete beginner in DDD) and stumbled upon a problem about the implementation of the web services... These are some ...
0
votes
0answers
31 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 ...
0
votes
1answer
88 views

log4net - roll my own singleton, use LogImpl, etC?

Reposting here... hopefully the better place to seek opinions on the matter. :) Writing my own log4net wrapper class using C#. I want to create a lib such that I can reference it from any ...
0
votes
1answer
111 views

To use or not to use a backing app for website?

By suggestion in comments, I'll try to rephrase my question to better reflect my problem: I have to present users (few at first, as many as possible later) with a website. There they will be able to ...
0
votes
0answers
13 views

What is the best solution for printing a document from Azure with limited user interaction?

I currently have a web app hosted in Azure, with a few worker background jobs. My goal is for a user to click print on a page, and to them the printer will magically start printing a document(for ...
0
votes
1answer
103 views

When getting a list of files to process, should I store them to a list of string, or a list of Stream? [closed]

for a list of files, coming from a list like from a file dialog is it better to store the list as a list of strings or should I convert each file to opened Streams stored in a List? For example ...
2
votes
6answers
299 views

Design pattern for method to accept one of several static items in C#?

I want to illustrated my question by way of a (hopefully) representative example. Lets say I have a situation where I am developing a class library in C# to be used in some simulations. I want to ...
0
votes
3answers
60 views

One Event Sent to Multiple Listeners, Want to Log Notification Once

I have a system in place where a Cache is made up of many Cache Nodes. When one is added, a CacheNodeAdded event is raised by the Cache. The Cache has a redundant set of Monitors listening for ...
1
vote
1answer
77 views

What design pattern can I use to represent processing data from any stream?

I'm reading data from a stream in buffered series of bytes (say 1024 bytes at a time) and do some comparison, checking, or processing, before writing it back to the same type of stream. Currently ...
3
votes
0answers
38 views

What to focus on when separating a monolithic codebase into separate (NuGet) packages?

I work on a fairly large web application. The main solution containing the web application project has over 100 projects. The average build time of that solution is 2 minutes on a 12 GB quad-core ...
2
votes
5answers
260 views

Create Database To Fit Data vs Make Data Fit The Database

I'm newish to programming and would like to know what people have found to be the most supportable option or rather what people find more understandable. I'm the only one writing code at my firm, but ...
4
votes
1answer
93 views

Mobile/Global User Authentication? (Non-domain and non-enterprise)

What is the current way to authenticate users in a mobile/global fashion? In other words, assume a mobile application. And if there is a database server in the backend, how would these users ...
1
vote
1answer
171 views

Separate namespace just for exceptions?

I was doing a code review and came across something odd which I've never seen before. The developer decided to create a sub-namespace just to contain all the assembly's exceptions. I thought I had ...
1
vote
1answer
45 views

Design: Mixed XML / Relational or Pure Relational?

Is it acceptable to model a very complex object graph using XML in the database, but leave the rest of a system in relational tables? I'd like to gauge opinion on this as I've hit a bit of a ...
0
votes
3answers
140 views

Is the Adapter the correct design pattern for this situation?

I have an instance of a class UntouchableClass of which I need to access the member variables to use in my DotLiquid template. Problem is, UntouchableClass has to inherit from Drop if I want to use it ...
3
votes
1answer
169 views

Should Libraries Use Events or a Set Action

I'm building a small reusable library for two systems our company manages. Something that I've been caught up on is whether I should expose a set of properties of type Action<T> for events such ...
2
votes
4answers
317 views

Is it bad practice to update an object in a static method?

Still learning .net and OOP and have a basic question I hope. This is an asp.net mvc app. Looking at the code below, I am most concerned with the line in CheckShippingVendor that says ...
0
votes
1answer
105 views

Whats an Ideal way to pass rules/options to methods that build SQL

We're trying to come up with a way to handle code that builds dynamic SQL for our application, which is very database centric. Things like Linq to SQL and Entity Framework are out of the question, so ...
3
votes
2answers
172 views

Is it a good idea to develop website that only has little access to DB? CRUD will be done by calling API provided by separate internal backend system

I'm going to start developing an application in near future. This application consists of : Back-end system. This system provides API to be used by client. This system connects to data store and ...
0
votes
2answers
138 views

How do I create single object that changes functionality based on programmer input?

I have several classes that all behave according to one interface. But in each class there are additional functions defined that give each class slightly different behavior. What I want to do is ...
2
votes
2answers
162 views

Pattern for multiple datasources

I've already read this question on CodeReview. I was hoping for general advice. I'm writing a service which will go to numerous data sources. Each source requires getting copious amounts of data ...
0
votes
3answers
163 views

Is it ok for services to reference one another?

I have a service that needs information implemented by another service in the same layer. Is it good practice for one service to take a dependency on another service in the same layer?
0
votes
1answer
145 views

What does the implementation of .NET string.Split(char[], StringSplitOptions) look like from inside?

That is if we were to see how Microsoft wrote this method what would it look like? I'm mainly interested in the use of the StringSplitOptions enumeration with the other parameter and how they probably ...
3
votes
1answer
343 views

Why doesn't VB.NET allow unnamed, one-line objects to be used?

Why isn't this allowed in VB.NET: New SqlCommand("some string", someSqlConnection).ExecuteNonQuery() Why would the language have been designed to require that this be used instead: Dim com As New ...
-1
votes
0answers
63 views

Best practices and tools for deploying .NET application to production [closed]

I'm working on a codebase for my company for a .NET MVC product. We have test, staging, and production environments. Test and staging are great - we use CI to grab files from our repo (not TFS; we ...
4
votes
3answers
502 views

Extension method naming convention [closed]

We are using some utility methods in our company to simplify programming. So we have following string extension: public static bool IsNoE(this string s) { return string.IsNullOrEmpty(s); } ...
0
votes
1answer
153 views

Limitations of using Hyper-V Virtual Machine as .NET Development enviroment

I've been thinking of using a Hyper-V Machine as instead of physical computer for installing my .NET / Azure / Xamarin / ASP.NET / Windows Phone development tools. That way I could easily move from my ...
0
votes
0answers
162 views

What are the shortcomings of using AuthorizeAttribute in this way in MVC?

I have ASP.Net MVC project code with custom authorization as below: public class UpdateAccrualAuthorize : AuthorizeAttribute { public override void OnAuthorization(AuthorizationContext ...
-1
votes
1answer
213 views

Better sticking with MDI or learning WPF? [closed]

I have a personal project I'm going to start working on soon. It will be database driven and have various screens that the operator may want to use. First thing I thought of was an MDI interface would ...
0
votes
2answers
104 views

How should I structure my namespace tree so that I have a Math class and Math namespace?

I don't know if this is a good or bad idea, or if it's technically even possible... but I'd like to have something of the following sort: public class Math { public int gcd(a,b) // Method for ...
0
votes
2answers
232 views

Model and ViewModel for View

I am new to the MVVM pattern. I have a window which has 3 text boxes (Name, Address, Description), a save button, and a listview which displays the above fields. When the save button is clicked I want ...