Tag | Programming Posts

I recently was going over a great book called “Dependency Injection in .Net” by Mark Seeman. So far I have really enjoyed the book and would recommend anyone looking to get into DI to give it a read. Today I thought I would blog about the first example Mark gives in his book to illustrate some of the benefits that DI provides. The ones he lists are Late binding Extensibility Parallel Development Maintainability Testability To illustrate some of these benefits he gives a HelloWorld example using DI ...
UPDATE: Thanks for the feedback and comments. I have adjusted my table below with your recommendations. I had missed a point or two. I wanted to do a series on creating an entire project using the EDMX XAF code generation and the SpecFlow BDD Easy Test tools discussed in my earlier posts, but I thought it would be appropriate to start with a simple comparison and reasoning on why I choose to use these tools. Let’s start by defining the term ORM, or Object-Relational Mapping. According to Wikipedia ...
O'Reilly are offering a series of good offers through to Jan 19, 2012. The main page is at http://shop.oreilly.com/cat... Already available are: JavaScript path to Mastery set at http://shop.oreilly.com/cat... I recommend JavaScript: The Definitive Guide, 6th Edition- PDF is 50% off at http://shop.oreilly.com/pro... HTML 5 Programming set at http://shop.oreilly.com/cat... Again the PDF's are 50% off. Can't ...
In this Issue: Michael Crump, Andrea Boschin, Michael Sync, WindowsPhoneGeek(-2-), Erno de Weerd, Jesse Liberty, Derik Whittaker, Antoni Dol, Walter Ferrari, and Jeff Blankenburg(-2-). Above the Fold: Silverlight: "10 Laps around Silverlight 5 (Part 6 of 10)" Michael Crump WP7: "31 Days of Mango | Day #2: Device Status" Jeff Blankenburg Metro/WinRT/W8: "Lighting up your C# Metro apps by being a Share Target" Derik Whittaker Shoutouts: Michael Palermo's latest Desert Mountain Developers is up Michael ...
The Obscure C competition is back at http://www.ioccc.org/ The Competition is open to the 12/Jan/2012. The aim of the competition is: To write the most Obscure/Obfuscated C program under the rules at http://www.ioccc.org/2011/r... To show the importance of programming style, in an ironic way. To stress C compilers with unusual code. To illustrate some of the subtleties of the C language. To provide a safe forum for poor C code. :-) Even if you are not a C programmer, it is worth looking at ...
In this Issue: Pontus Wittenmark, Jeff Blankenburg(-2-), Colin Eberhardt, Charles Petzold, Dhananjay Kumar, Igor, Beth Massi, Kunal Chowdhury(-2-), Shawn Wildermuth, XAMLNinja, and Peter Kuhn(-2-). Above the Fold: Silverlight: "Silverlight Page Navigation Framework - Learn about UriMapper" Kunal Chowdhury WP7: "31 Days of Mango" Jeff Blankenburg WinRT/Metro/W8: "An Introduction to Semantic Zoom in Windows 8 Metro" Colin Eberhardt LightSwitch: "Common Validation Rules in LightSwitch Business Applications" ...
© 2011 By: Dov Trietsch. All rights reserved Adventures with JavaScript rendered in IE 8, Chrome 15, and Firefox 8.0 I have written a little monogram about the advantages of Math and wrote a few JavaScript applications to demonstrate them. I was a bit careless and used elements on the page in my JavaScript without using any of the GetElementsByXXXX methods to identify them. Say I had a text box named tbSeqNum into which I entered a number to be used in a computation. In my code I simply referred ...
Yes, I was. Recently, I’ve taken a good hard look at JavaScript. I’ve used it before but mostly in the capacity of web design. Using JQuery to make your web page do cool stuff is different than really creating a JavaScript application using all of the language constructs. What I’m finding as I use it more is that I may have been wrong about my assumptions about it. Let me explain. I enjoyed doing cool stuff with JQuery but the limited experience with JavaScript as a language coupled with the bad ...
Today's $10 Deal of the Day from Apress at http://www.apress.com/97814... is Pro Dynamic .NET 4.0 Applications Data-Driven Programming for the .NET Framework "As a developer, you are likely painfully aware that not all features of an application can be anticipated when the software ships. In order to cope with these eventualities and save yourself time (and perhaps money), it makes sense to write your applications in such a way that end users can be made as independent of the developers as possible. ...
· For the last decade, the majority of my dev work has leveraged the .NET Framework for construction of information systems. However, my interest has lain in numerical computing. · Is it possible to have an increasingly higher level of abstraction and at the same time achieve underlying high performance computing? The prevailing winds say no: C# is aimed at productivity, and C++ is for performance. Garbage collection was great, but do we still need it with the availability of smart pointers? Would ...
Motivation During programming suddenly this error (“Failure has occurred while loading a type”) was thrown by accessing a artifact of a referenced library. In such cases I take the assembly fusion logger fuslogvw to search for problems of loading assemblies. Sometimes an old version from a not expected folder is binded. But all bindings were correct. Problem After several hour I got the right hint. Because the assembly is a COM+ one, there are some registration things in die background – and I don’t ...
Today O'Reilly have two excellent deals! Data Science Starter Kit Fundamentals of Microsoft .NET Programming Grasp the basic concepts that drive all Microsoft® .NET-based languages—and prepare yourself to learn .NET programming. If you have absolutely no previous experience, no problem—simply start here! This ebook provides the foundation for all other .NET programming language books in the Start Here! series. You’ll explore programming concepts and techniques with clear explanations, easy-to-follow ...
I recently have had the humbling experience of pair programming with several developers where I was just astounded at the speed at which they were able to get code generated. One thing I noticed is that most of their coding was done with the keyboard with very little use of the mouse – everything was shortcut based. When it was my turn to take over the wheel I found myself extremely slow compared to them, partly because I was not familiar with their keyboard and layout, but the majority of the slowness ...

 

Here are the slides and code samples for MVVM Programming Introduction given at TechEd Africa 2011

For those that attended my session on the complexities of asynchronous programming in WPF & Silverlight, find below the latest slide deck and code samples for download ...
In the closing keynote at TechEd Africa 2011, Clifford de Wit (Microsoft South Africa) made improvements on his previous years attempt to geekily give away a prize, but unfortunately still got it wrong… here’s why. At Teched 2010 Clifford gave away an amazing prize of a wheel barrow full of tech goodies – if my memory serves me right, it included a laptop, xbox, kinect as well as a whole bunch of other fun stuff – a geeks delight. Unfortunately he was given some flack on how he decided to pick the ...
Today TechEd Africa 2011 ended. It was a great conference and the first time I have ever had the opportunity to present an hour long topic – I had the joy of presenting two sessions at this conference, one session based on a topic which I should have been able to cover easily and one with a topic that I battled with and felt totally out of my depth. In retrospect, there are a few bits of advice that I would like to give other people that are thinking of presenting at a conference like this for the ...
It was another engaging presentation at this month’s CITAG meeting as Joe Hummel presented functional programming and its implementation using F#. Some times it is fun to attack a mind bending problem and this was one of those times. Leaning about functional programming caused about the same brain cramps as moving from procedural to object oriented for the first time. Of course when you start to get it the effect is almost euphoric. I would suggest that if you haven’t looked into functional programming ...
Last week, at the PASS (Professional Association for SQL Server) Summit in Seattle, Microsoft held a coming out party, not only for SQL Server 2012 (formerly “Denali”), but also for the company’s “Big Data” initiative. Microsoft’s banner headline announcement: it is developing of a version of Apache Hadoop that will run on Windows Server and Windows Azure. Hadoop is the open source implementation of Google’s proprietary MapReduce parallel computation engine and environment, and it's used (quite widely ...
I've made a list of programming books I've read, am reading and am going to read on the Bookshelved Wiki; would anyone care to recommend good books for a web-oriented, C# Agile programmer which I've not discovered or not considered?I've reproduced the list so far below for convenience :)Programming books on my 'to read' list Real World Functional Programming by Tomas PetricekCode Complete by Steve McConnellWorking Effectively With Legacy Code by Michael FeathersProgramming books being read at the ...
The great lesson of the Titanic was hubris, right? Perhaps. I don't know. What I do know is that there is another valuable lesson from the Titanic that is very applicable to software engineering: A failed implementation does not invalidate the concept. Titanic was designed by experienced engineers, using some of the most advanced technologies and extensive safety features of the time. It was built to be luxurious and safe. The cost of a first class ticket is equivalent to $100,000 accounting for ...
Hi Everyone, The only and main purpose of this blog is to educate all .NET pre-Beginners, who love to do .NET Programming but don't know where, what and how to do. Now you have a place to share and ask for that little thing that is holding you to move on your development. I was in your place 2 years ago, dont know anything about it, doesnt know where to start. I did googled(Bing'd) a lot, found so may articles, blogs about .NET and got very excited about it. Now I wanted to get all that information ...
I recently began feeling like it was time for a change. I have been programming in C# for about a year and so I felt the urge to learn something new. So I went to the library and checked out a book on Ruby programming. I chose Programming Ruby 1.9 written by Dave Thomas and part of The Pragmatic Programmers series. I figured I might as well document my journey into the new world of Ruby on my blog. I’ve gotten through about six chapters and I really like what I see from Ruby. It’s really fun to learn ...
I have dabbled in async programming in the past but never put any real effort into understanding how things worked. With the new async features in .Net 5 I thought I would give it a look. Here is a quick example of one of the features you can expect in the new framework and how it can make our life easier. The best way to illustrate this is to make a simple WPF application as follows… In the past If we had the following small WPF application with just one window / form… The XAML code for the window ...
As a developer of Microsoft technologies I alway think about what programming model and tools are provided by the platform. On Microsoft new operation system Windows 8 developer write two type of applications first one is Metro Style Apps and second one is Desktop Apps. Metro Style Apps Metro style apps are full screen apps tailored to your users' needs, tailored to the device they run on, tailored for touch interaction, and tailored to the Windows user interface. Desktop Apps Normal Windows applications ...
A reader of this blog wrote "It would be great to find out the reasons why programming languages are designed the way they are." The first computer languages were the assemblers. When I started programming in 1979, I learnt to read IBM360 machine code as well as write RPG, Cobol and CICS. Assembly languages are easier to use than writing directly in machine code. RPG stands for Report Program Generator and is an excellent language for writing reports to print on fixed pitch font printers. These were ...
Before I begin with the Milestone 1 recap, I have a few things I need to announce. To begin with, we need to help some kids! Every year, I participate in Extra Life. It's a charity that raises money for hospitals that are members of the Children's Miracle Network. I'm looking for sponsors. You can visit my donation page at http://www.extra-life.org/i... If you feel funny about not giving to your local CMN hospital, then ...
Today, we reached a new milestone of Microsoft All-In-One Code Framework. It gives me great pleasure to announce our newest Microsoft All-In-One Code Framework Sample Browser - v4 available to the globe. With this release, we embrace the hope of giving global developers a completely new and amazing experience to enjoy over 700 Microsoft code samples. Compared with the previous version, this new version of Sample Browser is completely redesigned from tip to toe. We heard lots of users’ voices about ...
I have been so busy with programming and project management, that I forgot all about this blog. I still get plenty of challenges and interesting issues every other day. I think it's time to start blogging about it. Just an update, I have moved to full ASP .Net web developement in the past few years, so no more WinForm stuff from me, except that Telerik Controls suck, and they have an unbelievable overhead and plenty of memory leaks. That's also true for their ASP .Net controls. It's horrible! For ...

At http://www.cs.cmu.edu/~rwh/plbook/book.pdf there is a free programming book on "Practical Foundations for Programming Languages"

Enjoy!

The time has come to begin the project. I am pleased to announce Card Roulette. All posts on the topic will include the tag "Card Roulette". The concept is fairly simple. One day, I was watching a biography of the man that invented the theory of card counting in Black Jack. While I was impressed with the math, I always felt that it was misleading. You're not really counting card, just keeping a few simple statistics. This nagged on me for a few weeks until I came up with the concept of playing Roulette ...
The recently ratified C++11 language specification provides a range of cool new features. Many of which have been part of other programming languages for some time now. One such new feature that I value a lot is the concept of lambdas. Lambdas are great in many ways. They enable you to create callbacks that are called for specific items, for instance, or you can implement events with them, as is the case in this blog post. The following is an example of an event implemented in C++11 using lambdas. ...
If you're working with large chunks of data, eventually you'll probably use a foreach loop to iterate through an enumerable data source and execute the same actions on each item (for example, do something to every DataRow in a DataSet). With the new Task Parallel Library (TPL) in .Net 4 you can execute these loops in parallel for a noticeable improvement in speed. .Net has had support for parallel programming since the 1.0 version, but the developer had to do (sometimes...) extensive work to create ...
At last, I can announce that ‘BizTalk Server 2010 Unleashed’ has been published and is available through major booksellers in both printed and electronic form. The book is not a new edition of the old ‘BizTalk Server 2004 Unleashed’ book from several years ago, although Brian Loesgen, our fearless team leader, provided continuity with that title. Instead, this is entirely new content written by a team of six authors, including myself. BizTalk Server is such a huge subject. It proved a challenge to ...
So its been a few weeks since Microsoft’s Build conference, where they unveiled Windows 8 and shared what the developer story will be. I had blogged about Day 1 of the conference here, but I wanted to share some video I took with my colleagues Winson Woo and Jim Russell as my thoughts now that a bit of time has lapsed. So first, a video captured right after we got our hands on the Samsung tablet given to all attendees. Yes the tablet is nice, but this conference is all about the OS. Windows 8 as ...
In this Issue: Michael Washington, Kunal Chowdhury, WindowsPhoneGeek, Xianzhong Zhu, Jeremy Likness, Pete Brown, Jesse Liberty, Derik Whittaker, Morten Nielsen(-2-), Sumit Dutta, Asim Sajjad, and Dhananjay Kumar. Above the Fold: Silverlight: "Enumerating MIDI Interfaces using Silverlight 5 PInvoke" Pete Brown WP7: "Migrating PushBox Game from Android to Windows Phone 7 - Part 5" Xianzhong Zhu Windows8: "Windows 8: What you Need to Know" Jeremy Likness LightSwitch: "How To Create a LightSwitch Command ...
I had written earlier about the WebMatrix v2 Beta release that happened recently at the BUILD Conference As I had mentioned earlier, WebMatrix is a light weight tool for Web Development, Profiling, Database management, Optimization and also deployment. Its an end to end tool for web developers. Web Matrix is different from Visual Studio in the sense, it doesn’t require web developers to master C#, ASP.NET and other programming techniques. Web Matrix uses a simple Razor syntax and HTML markup for ...

This is a quick tip, because it confused me at first. But thanks to the always excellent Tim Heuer and Peter Provost (from the Visual Studio team), here is the answer:

Usual disclaimer: This is for XAML/C#. I am not sure how this works for the other programming stacks.

Read the rest of this entry »

Something that took me a while to learn is how to be balanced when deciding on how to architect an application. Since at my current job I was thrown into a hybrid Architect/Developer position due to the small size of the company and my team, I didn’t really have any experience with doing it. After almost a year at it I decided to look back and see what I have done and how I can learn from mistakes and successes. Remember Why You Were Hired Why did your company hire you as a developer? If you answered ...
For more formatted view .. Goto http://ankitagrawal57.blogs... any web application, performance is basic necessity. Earlier internet speed used to be limited thus users got inclined to pages which load within 3-4 secs. But now the internet speed is no more a constraint but still time does remain a constraint. Imagine yourself visiting a website which takes a lot of time (30 – 60 secs) just to load the page. You would not like to go to that site again.To mitigate this issue, developers and ...
Todays Deal of the Day from O'Reilly at http://shop.oreilly.com/pro... is CLR via C#, Third Edition at $23.99 "Dig deep and master the intricacies of the common language runtime (CLR) and the .NET Framework 4.0. Written by a highly regarded programming expert and consultant to the Microsoft® .NET team, this guide is ideal for developers building any kind of application-including Microsoft® ASP.NET, Windows® Forms, Microsoft® SQL Server®, Web services, and console applications. You'll ...
What a week it has been! The BUILD Conference just concluded http://www.buildwindows.com... and there were tons of announcements. This is one of the reasons I am passionate about this company. Even when I was outside Microsoft, the momentum and the focus they have on Developer audience simply amazes me and they continue to do it, years later. Windows Developer Preview BUILD is a developer conference which premiered the first Windows Developer Preview bits. Clearly, the developers ...

Last week, Microsoft held their long awaited Build Windows (or simply "Build") conference in Anaheim CA. About 5000 people packed the convention center to discover the latest version of the Windows operation system: Windows 8.

Read the rest of this entry »

Programming for Metro Metro is the future http://zd.net/rnT9VZ .NET is for old apps. WinRT replaces WPF & WCF. XAML is big. There were no Silverlight sessions. HTML 5 and Javascript ( Blend for HTML) are back in fashion – I wont dwell on this because web apps are (inconsistently) simplistic in concept and over-complex in development. Yes, all those XAML skills are portable, Silverlight (RIP) apps can run as Metro apps with a bit of fidgeting with namespaces – you just need to know what controls ...
Tonight Windows 8 was released (LEGALLY) at least the Developer Preview edition was! You are able to get your own copy at http://dev.windows.com/. I have an interest in programming but an even greater interest in learning some of the new administrative tools available and things I can dig into a bit more and learn about Windows 8. I decided I was going to install it as a Virtual Machine. When I mounted the ISO it crashes upon startup, so I knew there had to be a setting somewhere I could tweak and ...
Just recently there was a great talk held by Herb Sutter at the C++ and Beyond conference. You can see the whole presentation at Channel 9. So why does C++ really matter anymore? All this time we’ve been talking about managed languages (Java, C#, Visual Basic.NET, the list goes on) increasing the productivity of development and being really the holy grail of computing where we don’t have to focus on memory allocation or really knowing anything about the underlying platform, for that matter. All this ...
One of the first developer jobs I had was programming in VB6 for a small business down the road. Up to that point I had been casually coding at school but this was my first exposure to “professional” development. To get the job I had to do a weeks worth of work and then get it reviewed by the boss. I thought I did a pretty good job until I got his review back and he criticized everything – in particular he ripped apart my naming conventions (or lack of them). In memory of this event I thought I would ...
Yeah, you read that right. I may be weird, but I do think that unit testing is fun. It is also very important. I didn’t know much about Unit testing when I came out of school. I think colleges need to have a class dedicated to it. But anyway, I didn’t do much of it at my previous job since I was developing the Siebel CRM. Since Siebel is an Oracle product, it involves mostly configuration and customization using built components. We did some integration testing by building any new components into ...
(Warning: This is semi-advanced stuff. It’s not hard, per se, but it involves editing important project files manually, which, if done wrong, can render them useless making it so that your code won’t compile (and may not even load into Visual Studio). So back up everything or (better still) commit it to your source control repository before doing anything so that in case you mess something up, you can easily recover! You have been warned.) I’ve been steadily becoming more familiar with MSBuild over ...
Today's $10 Deal of the Day from APress at http://www.apress.com/97814... is SharePoint 2010 as a Development Platform. "This book takes an in-depth, all-encompassing approach to programming concepts, the extensibility interfaces, and how to embrace SharePoint as a toolkit full of features available to web developers. " ...