Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Convert an array string to VFP cursor/array
Message
 
 
To
07/01/2017 08:29:44
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
01646369
Message ID:
01646386
Views:
741
Thank you. I will try this approach.

>It might help if you start by converting this into an array. I.e.:
>* Remove the braces
>* Use alines() to convert to an array (using the ":" as a separator)
>* Then you can parse each individual array element. For example, the first element will contain the text:
>"Version":"2.2222"
>
>>Hi,
>>
>>In one place of my app, the response of the Web API call is an "array" (I put the array in quotation marks because this is not exactly a VFP array). The "array" string looks like this:
>>
>>{"Version":"2.2222","Connected":true}
>>
>>
>>I suppose I can parse this string to get the values. But I was wondering if there is a "better" way to convert this string to an array or a cursor?
>>
>>TIA
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Reply
Map
View

Click here to load this message in the networking platform