chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
01/30/13 04:22 PM (12 years ago)

Dynamically changing JSON value in Java

How might I go about changing a JSON value for a parent's screenData? I can retrieve the JSON object easily enough via: String tmpValue = BT_strings.getStyleValueForScreen(screenData, "someJSONKey", ""); But, what if I want to change the value of that "someJSONKey" in code? I started down the path of screenData.setJsonObject(), but got stuck with creating a JSONObject. Is that the right way to do it?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
01/30/13 05:38 PM (12 years ago)
In Java I have no clue. Of course, in iOS I have no clue either, so I'm following... Currently, I'm working on a project that starts off with a menu screen. So far, that's the only screen in my BT Project. The rest of the screens are generated dynamically depending on the menu choices (of the dynamically created menu items of the first screen...), therefore I have autonomy over the parent, child, or whatever. This is all done via PHP to create json data for new menu screens or to populate an HTML screen. All screens (except the initial menu) is created on the fly. Would that suffice? or does it need to be 'pre-built' screens? Cheers! -- Smug
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
01/30/13 08:11 PM (12 years ago)
It's for a plugin I'm creating. I found another way around the issue, though. But, still, I would like to know the answer as a learning point.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.