# FXTable - iterating through headers

**URL:** <https://www.ruby-forum.com/t/fxtable-iterating-through-headers/174254>\
**Category:** FXRuby\
**Created:** [August 23, 2009, 5:57pm UTC](https://www.ruby-forum.com/t/fxtable-iterating-through-headers/174254 "2009-08-23T17:57:41Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ymeth](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/6f9a4e/32.png) [@ymeth](https://www.ruby-forum.com/u/ymeth)\
**Post date:** [August 23, 2009, 5:57pm UTC](https://www.ruby-forum.com/t/fxtable-iterating-through-headers/174254/1 "2009-08-23T17:57:41Z")

</div>

Hi,

my question concerns FXHeaders in an FXTable  
As the title says I’m trying to iterate through each header in order to  
get it’s text. However, im getting some very strange errors (that is:  
strange to me).

Here is the code:

def generate\_view§  
@tabelle.columnHeader.each do |header|  
x = header.position  
foo = header.getItemText(x)  
end  
end

When the method gets called, the compiler says: “undefined method  
`position’ for :Fox::FXHeaderItem (NoMethodError)”

Now, I’m relatively new to programming, so this might be a completely  
dumb question, but where is my mistake?

Thanks  
Patrice
