title: Get values from a JSON array nested in another array for use in codenameone project using a loop
body: <p>I have a JSON array that has two other arrays in it. I would like to retrieve values from both arrays using a loop. the arrays are from a hashed table. Am doing this in a codenameone project. Here is me array from a hashtable:</p>
  
  <pre><code>{2={company=helsana, monthly_amount=100, gender=male, dob=2007, vorname=King, fname=Brian , cid=1, id=2}, 1={company=helsana, monthly_amount=150, gender=female, dob=1985, vorname=King, fname=Lorna, cid=1, id=1}}
  </code></pre>
  
  <p>Here is my code to get the values so far, which is so not working. Am stuck(I have put "?" where I don't know what to use to get the values). The values are "fname" and "vorname" from each of the arrays. </p>
  
  <pre><code>final String[] anArray;
               final String[] secArray;
               anArray = new String[]{String.valueOf(h.get(?))};
               secArray = new String[]{String.valueOf(h.get(?))};
  
  
               final Button[] button = new Button[h.size()];
               for (int i = 0; i &lt; h.size(); i++) {
                  button[i] = new Button(); 
                  button[i].setIcon(fetchResourceFile().getImage("personIconBig.png"));
                  button[i].setText(""+anArray[i]);
                  final String name = String.valueOf(anArray[i]);
                  final String secname = String.valueOf(secArray[i]);
  
                  button[i].addActionListener(new ActionListener() {
                  @Override
                  public void actionPerformed(ActionEvent e) {
  
                      findName().setText(name);
                      findVorname().setText(secname);
                      findFamMname().setText(name+" "+secname);
                      findFamMname().setIcon(fetchResourceFile().getImage("personIconBig.png"));
                      findFamMname2().setText(name+" "+secname);
                      findFamMname2().setIcon(fetchResourceFile().getImage("personIconBig.png"));
                      findDeleteMember().setVisible(true);
  
                      c.getComponentForm().revalidate();
                      c.getComponentForm().repaint();
  
                      }
                  });
  </code></pre>
  
  <p>Thank you for the help in advance.</p>