How to: Hash reference using text variable

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Marv
    New Member
    • Jul 2006
    • 2

    How to: Hash reference using text variable

    Let's say you have a hash of hashes and you access one of its values like this

    print "$myhash->{ParentKey}->{ChildKey}";

    and that actually prints: myValue

    But now, you want to store the access path in a text variable like this

    $txtvar = "{ParentKey }->{ChildKey}";

    and you want to print myValue,

    How in the wolrd you do that? :confused: Hope you can help me
Working...