Hmm.. I'm wondering if this is result of the autogeneration. I would *think* that when you bind the grid, it generates the columns. But it's possible this is not where it happens. So because you don't have a specific columns node in the markup, at this point in the execution, there are no columns in the columns collection.
Can you try outputting some debug information before/instead of doing the header text assignment, and see what the columns collection Count is? This will probably shed some light on the problem.
|