Ruby tk

I NEED TO REMOVE ELEMENTS FROM A TKVARIABLE.NEW_HASH I AM USING TKTABLE
PLEASE HELP ME

From: Jesus J. [email protected]
Subject: RUBY TK
Date: Fri, 6 Mar 2009 09:19:28 +0900
Message-ID: [email protected]

I NEED TO REMOVE ELEMENTS FROM A TKVARIABLE.NEW_HASH I AM USING TKTABLE
PLEASE HELP ME

$ irb -r tk
irb(main):001:0> v = TkVariable.new_hash(‘aaa’=>1, ‘bbb’=>2, ‘ccc’=>3)
=> #<TkVariable: v00000>
irb(main):002:0> v.value
=> {“aaa”=>“1”, “bbb”=>“2”, “ccc”=>“3”}
irb(main):003:0> v[‘ddd’] = 4
=> 4
irb(main):004:0> v.value
=> {“aaa”=>“1”, “bbb”=>“2”, “ccc”=>“3”, “ddd”=>“4”}
irb(main):005:0> v.unset(‘bbb’)
=> true
irb(main):006:0> v.value
=> {“aaa”=>“1”, “ccc”=>“3”, “ddd”=>“4”}
irb(main):007:0>

Jesus J. wrote:

I NEED TO REMOVE ELEMENTS FROM A TKVARIABLE.NEW_HASH I AM USING TKTABLE
PLEASE HELP ME

A> PLEASE DON’T SHOUT! That’s what it looks like when we are all typing
in
downcase…

B> Please prep such questions with Google (or a comparable search
engine), and
be prepared to report how its citations failed you. Otherwise, our
forums will
fill up with the same FAQs, and we would lose interest in responding!

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs