• Well it seems to me you are trying to parse a XML response with JSON.parse. You will need a XML parser to get what you want.

    If you are just interested in the BinaryState Tag value you can get by with a regex if they are supported.

    // Gives you the value of BinaryState
    let binaryState = /<BinaryState>(\d)<\/BinaryState>/.exec(­pdata)[1];
    
About

Avatar for PaddeK @PaddeK started