aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes array of values from JSON object Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "array of values from JSON object" Watch "array of values from JSON object" New topic
Author

array of values from JSON object

thomas silver
Ranch Hand

Joined: Jun 20, 2003
Posts: 32
I am aware that an array of keys can be obtained as follows:



I was just wondering if there is a way to obtain array of values for a row. TIA.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61232
    
  66

Some context would be nice. What is row for example?

Also, please be sure to use code tags when posting code to the forums. Unformatted or unindented code is extremely hard to read and many people that might be able to help you will just move along to posts that are easier to read. Please click this link ⇒ UseCodeTags ⇐ for more information.

Properly indented and formatted code greatly increases the probability that your question will get quicker, better answers.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
thomas silver
Ranch Hand

Joined: Jun 20, 2003
Posts: 32
Hi Bear, row is any singular one dimensional extraction from json object. For example (have not been tested),


Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61232
    
  66

OK, so what's the question? comedians is already an array.
thomas silver
Ranch Hand

Joined: Jun 20, 2003
Posts: 32
I figured it out. I will post solution later. Thanks.
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Well your code



gets the names, so you would have to do row[key] to get the values.

Eric
thomas silver
Ranch Hand

Joined: Jun 20, 2003
Posts: 32
Eric, yes that was what I did

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: array of values from JSON object