-2

In my Parse Config I have this parameter:

lastRatio Object {"ratio":10000,"time":300}

How can I access to it from android? I tried this so far but didn't work

ParseConfig.getInBackground(new ConfigCallback(){
                             public void done(ParseConfig config, ParseException e){
                                 Object ratio = config.get("lastRatio");
                                 Toast.makeText(RequestServiceActivity.this, "Ratio: "+ ratio, Toast.LENGTH_LONG).show();

ratio is {"ratio":10000,"time":300} always, I only want to acces to "ratio":10000

Alxlly
  • 61
  • 1
  • 10

1 Answers1

0
String ratio=config.getString("ratio");

by this you can access value of object ratio ="1000"

Viraj Patel
  • 211
  • 2
  • 5