I am getting a response from the server as below,
<p style="font-family:Arial, Helvetica, sans-serif; font-size:18px;"> <strong>XXX Pvt Ltd. has been used 3 times.The contact information for XXX can only be viewed -4 more times on App until it expires. Please urgently verify the information.</strong></p>
Here I would need the integer value -4 if it is negative or 4 if it is positive. In case it is negative I would like to get it with the negative sign.
Is there any way to clip all the text values and just get a part of the response from the server in android?
I actually need the count of times we can see the info above in my app.
I tried researching and gone through some links as,
Remove all occurrences of \ from string
How to replace the characher `\n` as a new line in android
How to strip or escape html tags in Android
However, none of this could actually help me in achieving what I want.
Please, can anyone help?