brandewinder

Stories submitted by brandewinder

Solve math optimization problems with C# and the Microsoft Solver(www.clear-lines.com)

submitted by brandewinderbrandewinder(530) 6 months, 16 days ago

The Microsoft Solver Foundation is a great tool to solve mathematical optimization problems, right in your .NET code. This post illustrates how you can integrate it with your own object model, and use it to dynamically find solutions to a problem prototype, for any range of inputs. read more...

add a comment |category: |Views: 8

tags: another

First steps with the Microsoft Solver Foundation(clear-lines.com)

submitted by brandewinderbrandewinder(530) 6 months, 27 days ago

This post illustrates how the Microsoft Solver Foundation, a free tool from Microsoft, can be used to resolve mathematical and optimization problems, from within your .NET code. read more...

add a comment |category: |Views: 8

tags: another

Select dynamically how to sort a list(www.clear-lines.com)

submitted by brandewinderbrandewinder(530) 1 year, 3 months ago

Sorting lists of items using LINQ is straightforward, by applying OrderBy, using whatever item property you want. However, I recently had to solve a slightly more complex problem: providing the user with the ability to select between multiple sorting criteria. How could we implement this without code duplication? read more...

add a comment |category: |Views: 8

tags: another

On the road from C# to F#: more stocks reading(www.clear-lines.com)

submitted by brandewinderbrandewinder(530) 1 year, 7 months ago

Last time we retrieved historical stock quotes from Yahoo's website using F#; now we’ll break the web response into quotes, explore some more functional concepts, and create a small script. read more...

add a comment |category: |Views: 6

tags: another

Reading stock quotes from Yahoo finance using F#(www.clear-lines.com)

submitted by brandewinderbrandewinder(530) 1 year, 7 months ago

F# tutorial: how to retrieve historical stock quotes from Yahoo finance webservice using F#, with comments for the developers coming from a C# background. read more...

add a comment |category: |Views: 105

tags: another

Excel 2007 VSTO add-in tutorial(clear-lines.com)

submitted by brandewinderbrandewinder(530) 1 year, 8 months ago

A step-by-step tutorial on building an Excel 2007 VSTO add-in, using .Net, WPF and MVVM, the Ribbon and Custom Task Pane, to extend Office and create a friendly user interface to identify and highlight differences between two worksheets. read more...

add a comment |category: |Views: 123

tags: another

Why testing for exceptions with NUnit 2.5 is better(clear-lines.com)

submitted by brandewinderbrandewinder(530) 2 years, 8 months ago

The popular unit testing framework NUnit 2.5 is out. Among lots of changes, one of the most significant ones is the replacement of the [ExpectedException] attribute by the new syntax Assert.Throws. This post discusses some of the benefits of this change. read more...

add a comment |category: |Views: 24

tags: another

The Art of Debugging – A Developer’s Best Friend(blogs.msdn.com)

submitted by brandewinderbrandewinder(530) 3 years ago

Art is the process or product of deliberately arranging elements in a way that appeals to the sense or emotions. It encompasses a diverse range of human activities and I think debugging is an art form. There's nothing more beautiful (almost nothing) than watching your errant code expose it's semi-flawed algorithmic beauty. And nothing appeals to my emotions more than make my code more robust and more efficient after watching the debugger execute it one line at a time. read more...

1 comment |category: |Views: 8

tags: another

Action, Func, Predicate - what's going on?(blogs.vertigo.com)

submitted by brandewinderbrandewinder(530) 3 years ago

This post covers Action<T>, Func<T>, Predicate<T> and shows them in action. These delegates are generalization (abstractions?) over some common method signatures and you might find them very handy. Besides making LINQ possible, they should help you stop writing your own custom delegates and replace them with these generic ones. read more...

1 comment |category: |Views: 1719

tags: another

Using Prism (Composite WPF) EventAggregator(blog.donnfelker.com)

submitted by brandewinderbrandewinder(530) 3 years, 1 month ago

Imagine that your "Services" layer needs needs to send off an event that some data has changed. One way to do this would be to bubble the event to the parent layer and then let that layer bubble the event up again. For example, lets say that the Service layer changed the Customer and it wants to let any interested parties know (as it should) through an event. So it sends a "CustomerChanged" event notification. Since the only object who is watching the Service layer is the Model layer, the model layer will grab the event and then re-publish it again (bubbling it up) the object graph). As you can tell, its a royal pain to do this. Imagine the amount of code you have to write. You've to write a ton of plumbing just to bubble the event from the service to the model to the view model to the view, and vice versa. This is where an event aggregator comes in. read more...

add a comment |category: |Views: 168

tags: another

How IoC containers fit in an application architecture.(blogs.msdn.com)

submitted by brandewinderbrandewinder(530) 3 years, 1 month ago

There is surprisingly little information out there in cyberspace on how IoC containers should fit into application architectures. I'm going to discuss some of the principles that I believe should be applied to "container-managed" application design. read more...

add a comment |category: |Views: 30

tags: another

Generic Repository(codebetter.com)

submitted by brandewinderbrandewinder(530) 3 years, 1 month ago

The purpose behind the repository pattern is to provide a layer of abstraction between your domain and data layer. For smaller projects, this typically isn't needed. However, larger projects can really benefit from a broker that specifically handles the back and forth between the two layers. With repositories your domain objects aren't burdened with infrastructure details and can therefore better focus on domain-specific behavior. read more...

add a comment |category: |Views: 1207

tags: another

Vexing exceptions(blogs.msdn.com)

submitted by brandewinderbrandewinder(530) 3 years, 5 months ago

A typology of exceptions (fatal, boneheaded, vexing and exogenous), and how you should handle them. read more...

add a comment |category: |Views: 10

tags: another

Adding satellite assemblies to your VSTO add-in(clear-lines.com)

submitted by brandewinderbrandewinder(530) 3 years, 5 months ago

How to add custom actions to the deployment project of an Office 2003 VSTO add-in solution, to make sure that if you reference a dll, it gets properly installed and granted security trust. read more...

add a comment |category: |Views: 14

tags: another

Should my unit tests access the database?(haacked.com)

submitted by brandewinderbrandewinder(530) 3 years, 6 months ago

Why you should abstract away the data access to improve testability - and why that doesn't mean you should NOT test your code’s interaction with the database. read more...

add a comment |category: |Views: 10

tags: another

Arrange Act Assert and BDD specifications(lostechies.com)

submitted by brandewinderbrandewinder(530) 3 years, 6 months ago

With Rhino Mocks 3.5 just around the corner, I've started using it to create much more readable tests. One of the things that always bothered me with Expect.Call, constraints and the like was that it mixed in the Arrange with Assert. For those that haven't heard of AAA, it's a pattern for authoring unit tests: * Arrange - set up the unit under test * Act - exercise the unit under test, capturing any resulting state * Assert - verify the behavior through assertions As I moved towards BDD context/specification style tests, working with Rhino Mocks didn't fit the picture very well. But with the new AAA syntax of Rhino Mocks 3.5, I can very cleanly separate out the behavior I want to observe from the mechanics of setting up the test. read more...

add a comment |category: |Views: 162

tags: another