Hello;
My code work well on debug mode. But; I recive an error on Realese mode.
After I changed code and I added first line " RETURN", I cant see this error.
Where is bug???
My code work well on debug mode. But; I recive an error on Realese mode.
B4X:
Sub hc_ResponseSuccess (Response As HttpResponse, TaskId As Int)
Dim x As String
x=Response.GetString("UTF8")
Log(x)
'Gelen data
Dim a As String
If x.IndexOf("<short_name>TR</short_name>")>0 Then
Dim a1,a2 As Int
a1= x.LastIndexOf2("<short_name>",x.IndexOf("<type>administrative_area_level_1</type>"))
a2= x.LastIndexOf2("</short_name>",x.IndexOf("<type>administrative_area_level_1</type>"))
If a1>0 And a2>0 And a1<a2 Then
GPS_il=x.SubString2(a1+12,a2)
Log(GPS_il)
End If
Dim a1,a2 As Int
a1= x.LastIndexOf2("<short_name>",x.IndexOf("<type>administrative_area_level_2</type>"))
a2= x.LastIndexOf2("</short_name>",x.IndexOf("<type>administrative_area_level_2</type>"))
If a1>0 And a2>0 And a1<a2 Then
GPS_ilce=x.SubString2(a1+12,a2)
Log(GPS_ilce)
End If
End If
'Log(x)
End Sub
After I changed code and I added first line " RETURN", I cant see this error.
Where is bug???