# Wednesday, January 31, 2007

Tagged by Brendon

OK, so I was tagged by Brendon quite some time ago. Here are 5 things you may or may not know about me, but probably do not:

  1. I am really picky about the comfort of my clothes. This drives my wife nuts. Especially when I remove the tags from most of my shirts (they itch!).
  2. Food that is supposed to be warm is utterly revolting to me when cold. The mere thought of cold pizza sends a shiver down my spine. I don't mind eating leftovers, but my wife has to open the refrigerated container and heat it (I can't even be in the same room - I can pick up the foul smell of cold leftovers from 20 feet away).
  3. I can smell several offensive odors from a good distance. If you eat something with heavy garlic, onions, or curry, then I can generally smell you sweating the odors for up to two days afterward. Coffee and asparagus I can also detect for up to 12 to 24 hours. When I have a cold though, I cannot smell any of it.
  4. I am hooked on XBOX Live gamerscore points. At 5295 points, I finally surpassed Shawn. My next goal is 10k points, which I hope to reach by mid-year. I did not own an xbox until 7 months ago, so hitting a 10k score is not unheard of.
  5. People who insist on talking or interrupting a movie are at the very top of my peeve list. I like to watch a movie from start to finish without interruption and without being asked questions. This is why I rarely go to the theater, and why when I actually do watch a movie, I try to do it without my wife being there (she feels compelled to talk through a movie and to try to get my attention when I am obviously focused on the film).

So there you have it, 5 things about me. The good thing about waiting a full month to respond to the tag is that I don't really know 5 other regular bloggers who haven't already been tagged, so I am going to terminate this branch of the blogtag. After all, chain letters inevitably end with someone unable to continue the chain.

Wednesday, January 31, 2007 1:05:24 PM (Eastern Standard Time, UTC-05:00) #  Disclaimer | Comments [0] | 

# Thursday, January 25, 2007

Team Leadership

One of the skills I have had an opportunity to sharpen over the past year has been Team Leadership. And I would like to take a moment to get my thoughts "on paper" for those who might be reaching a point in their own career where the information could be useful.

It's not really something I thought much about before coming to Intellinet - it was always something that had been thrown upon me, and I was expected to quite simply "sink or swim". Luckily for myself and the projects I was involved in, I always landed on my feet and did at least an OK job with leadership - even if I had no idea what I was doing at the time.

Fast-forward to Intellinet, my responsibilities here, and my participation in an internal leader training program modeled on the writings of Andy Stanley, who also happens to be a highly successful pastor for what some would call a "megachurch" based in Alpharetta. Through this program, we studied his "Next Generation Leader", a very short (160 pages) book that attempts to convey his thoughts on what makes a good leader.

Of the many things learned through this experience, the one thing that was truly eye-opening is his Andy's assertion that "leadership is about having and conveying clarity and vision in a sea of uncertainty". In other words, a good leader does not simply follow a pre-mapped course - if so then he would merely be just a guide. A good leader rises through confusion and uncertainty, defines the path ahead, and drives forward towards that end goal - with willing followers in tow.

That's not the only thing we learned however. We also learned that leadership is earned - it is not something that people will usually give to you simply because of title or rank. Not only is leadership earned, but it comes through strength in character and morals (moral authority)... people will not follow a corrupt leader for long.

The last really big thing I picked up from the leadership study sessions - in Andy's words "Only do what only You can do". There is a strong tendency to try to improve skills that you are lacking in - in an effort to achieve "balance". In fact, this just draws focus away from the things that we have a natural strength in. Besides, by focusing on the things we are naturally good at, we can make room for others who are natural complements to our skills - who themselves have a natural strength in those areas where we are weak. And that's what team-building is all about.

Anyways, I could go on about this for a few pages more... but would rather not spoil the entire book in case you might be considering giving it a read. Its good stuff - and now I at least understand why and how some things work well in a leadership position and others do not.

Thursday, January 25, 2007 11:45:05 PM (Eastern Standard Time, UTC-05:00) #  Disclaimer | Comments [1] | 

# Tuesday, January 09, 2007

Adventures in Databinding ~ Part 2 ~ Simple versus Complex Binding

Databinding in .NET is immensely powerful. You can bind nearly any property of any object to any property of any control. The source object can be any .NET object - a business component, a DataSet, a built-in .NET class, or even another Control! Of course like any powerful feature, the Devil is in the Details.

Simple versus Complex Binding

To understand the databinding system first requires acknowledgement that there is in fact two "flavors" of databinding. You can bind to two very different categories of objects, and this is what differentiates the flavors of binding. The two flavors are called Simple and Complex binding. This is somewhat of a misnomer in my opinion as there is nothing inherently more complicated about Complex binding - it's just different. I would prefer to call these two forms of binding Item and List binding, as that more accurately describes their use. In fact, I will try to refer to them as such throughout these posts.

Item Binding

Item Binding refers to the connection of a source object property value to a target control's bindable property. These connections are typically two-way, in other words you can change either side of the connection and the databinding system will push the change to the other side. Another cool aspect is that you can bind many controls to the same source property - however you cannot bind a control's property to more than one source. An example of this would be binding the Text property of a Label control to the FirstName string property of a Customer object.

List Binding

List Binding refers to the connection of a source list of objects to a target control that is capable of display and/or navigating between multiple items in the list. The source list can be any .NET object that implements IList, ICollection, IEnumerable or IBindingList, including arrays, collections, generic lists, and DataTables. In more advanced scenarios, an object that implements IListSource can also be used - IListSource simply defines a list of lists. Controls that are able to participate in List Binding include the ubiquitous DataGrid/DataGridView, and many other controls that consume lists of items for various reasons - DropDowns, ListBoxes, and TreeViews to name a few.

Mixing and Matching

Unfortunately, you usually cannot mix (or should not mix) both Item and List Binding in the same source objects. Due to the way the databinding system discovers and uses databinding interfaces (will be discussed in a followup topic), it is not possible to have both Item and List bindings on the same object. An example of this would be binding to Customer entries in a list as well as the Count property of the list itself.

Examples

Item Binding Examples

When creating Item Binding connections, you always begin with the target control, and add to its DataBindings collection a list of property names and their sources. DataBindings.Add() is an overloaded method with two main usage scenarios. Most of the time you will use the form of Add(PropertyName, DataSource, SourcePropertyName). In more rare situations you might want to create a Binding object directly and and use the form Add(Binding)... this can be useful when you want to override default formatting and parsing of values.

  • Binding to a property of a business object

Customer C = new Customer("John");

TextBox TextBox1 = new TextBox();

TextBox1.DataBindings.Add("Text", C, "FirstName");

-or-

Binding B = new Binding("Text", C, "FirstName");

TextBox1.DataBindings.Add(B);

  • Binding to a public field of a business object

You can't do it in this version of the framework!

  • Binding to a field in a DataTable

DataTable CustomerDT = new DataTable("Customers");

CustomerDT.Columns.Add("FirstName", typeof(string));

CustomerDT.Rows.Add(new object[1] {"John"});

TextBox TextBox1 = new TextBox();

TextBox1.DataBindings.Add("Text", CustomerDT, "FirstName");

  • Binding multiple controls to the same source data

CheckBox CheckBox1 = new CheckBox();

TextBox TextBox1 = new TextBox();

TextBox1.DataBindings.Add("Enabled", CheckBox1, "Checked");

List Binding Examples
  • Binding a grid to a DataTable

DataSet CustomerDS = new DataSet();

DataTable CustomerDT = CustomerDS.Tables.Add("Customers");

CustomerDT.Columns.Add("FirstName", typeof(string));

DataGrid CustomerGrid = new DataGrid();

CustomerGrid.DataSource = CustomerDT;

Note that the following can also replace the above DataSource assignment:

CustomerGrid.DataMember = "Customers";

CustomerGrid.DataSource = CustomerDS;

However, it is very important to realize that while on the surface they may appear to give identical results, these datasource assignments are not the same! I will explain this further in part 6 of this series.

  • Binding a ComboBox to an array

string[] StatusList = new string[2] {"Active", "Canceled", "Completed"};

ComboBox CurrentStatus = new ComboBox();

CurrentStatus.DataSource = StatusList;

Note that with a ComboBox, the List Binding is what is used to supply the list of possible values displayed when activating the control.

  • Binding a ListBox to a Business Object Collection

List<Customer> CustomerList = new List<Customer>;

CustomerList.Add(new Customer("John"));

CustomerList.Add(new Customer("Mary"));

ComboBox CustomerSelection = new ComboBox();

CustomerSelection.DisplayMember = "FirstName";

CustomerSelection.ValueMember = "CustomerID";

CustomerSelection.DataSource = CustomerList;

Note that ListBox controls, like ComboBox controls, use a List Binding to supply values for the range pf possible values. They both can also use an Item Binding to connect the actual currently selected value to a data source object.

To Be Continued...

Tuesday, January 09, 2007 12:21:26 AM (Eastern Standard Time, UTC-05:00) #  Disclaimer | Comments [2] | 

# Sunday, January 07, 2007

Adventures in Databinding

Why would I care about Databinding?

Perhaps you are just writing some server code. Maybe XML processing, web services, or even some good old-fashioned application server components. If so, then maybe you really shouldn't care about Databinding.

But maybe - just maybe - you are building the User Interface for an application. Or perhaps a set of business objects that will eventually be displayed in a User Interface. And maybe, just maybe, that interface happens to live in the world we now call "Smart Clients". If so, then three paths will lay before you:

  1. You can pretend that databinding does not exist and manually update/read data values directly from UI controls.
  2. You can try to ignore the intricacies inherent to databinding and hope that everything works out (might be OK if nothing in your UI is "outside of the box").
  3. You could embrace the beast that is .NET Databinding, study and plot against your foe, and finally prevail against that poorly documented adversary which has terrorized legions of .NET developers.

OK, well maybe it's not quite that exciting, but there is definitely some interesting (I think) stuff to be learned when you take a deeper dive into the world of .NET Databinding.

In a series of topics I hope to shed some light on this dark and often cursed part of the .NET infrastructure. In my past few years of .NET experience I have had to tackle databinding from many angles, and have managed to develop a fairly good grasp of the subject (I think - ...always more to be learned). Hopefully I can share some of that with readers. So let's see where this goes...

Sunday, January 07, 2007 3:52:55 PM (Eastern Standard Time, UTC-05:00) #  Disclaimer | Comments [2] | 

# Friday, January 05, 2007

Crawling back out of my cave

For nearly a year I have been bogged down in what I can only describe as a quagmire of a project. But this week that all changes - I am moving on to some new work finally, and maybe - just perhaps - I will have more time to blog about the things I have learned and re-learned during that time...

Friday, January 05, 2007 4:22:26 PM (Eastern Standard Time, UTC-05:00) #  Disclaimer | Comments [0] | 

2007 Atlanta Code Camp - Registration is OPEN

As announced earlier today by Jim Wooley:

 

 

Fellow Code Campers,

I hope you all had a wonderful holiday season and I want to wish everyone a Happy New Year.

Registration for the 3rd annual Atlanta Code Camp is now open. Please register on the Click to Attend website to guarantee your spot at the Code Camp.

Here's the link:
https://www.clicktoattend.com/invitation.aspx?code=113135

Just a reminder. The 3rd annual Atlanta Code Camp will take place on January 20th. The event is completely free and lunch is included. Doors open at 7:30am at the Decatur campus of DeVry University

250 North Arcadia Ave
Decatur , GA 30030

If you are coming in from out of town, we have a recommended hotel near the event. Call the Holiday Inn and ask for the DeVry University rate to get a $99/night rate. Parking is extra and costs $7/day

Holiday Inn

130 Clairemont Ave
Decatur, GA 30030
404-372-0204

During the Code Camp, lunch will be provided at no cost to you. After the event, we are planning on gathering in a local eatery to continue any discussions which we were not able to complete by our 5:30 pm end time. Location information will be made available at the event.

The Atlanta Code Camps have historically "sold out" extremely rapidly and we don't expect this time to be any different. Please register quickly to lock in your spot as we are capping registration and attendance due to facility limitations.

.NET | Events | General
Friday, January 05, 2007 3:55:47 PM (Eastern Standard Time, UTC-05:00) #  Disclaimer | Comments [0] | 
View Keith Rome's profile on LinkedIn

On this page....

Archives

Navigation

Categories

About

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

Sign In

Certification Logo Certification Logo Certification Logo Certification Logo Certification Logo

Powered by: newtelligence dasBlog 2.3.9074.18820