Geolocation API with Opencage Data (NEW!)

Did you add get json from object block?

image

1 Like

I try not to meet with the bad guys and for this reason, with my project a lot less problems.

2 Likes

@actech is saying that Global Variables are not needed.

I will also say that, they are not needed.
Your code should be like this -

image

Thanks! :blush:

2 Likes

thanks actech

still not getting the data :frowning:

Now I understand! You not correctly get the data!

if < [(status) = (200)]
do get data…

2 Likes

You need to check the error now.

1 Like

Do like this, it’s efficient.

1 Like

still no data in lable5

Now I understand! You not correctly get the data!

if < [(status) = (200)]
do < get data…

2 Likes

x is the variable of the do something func.
Will nit work under the response block…

1 Like

@actech
problem - he is using local var “x” as a global var :sweat_smile:

1 Like

No, x - a global variable within the screen. Here, everything is correct. Of these local variables in Thunkable X no.

1 Like

the var X is from the do-something procedure, will work only in that block.

1 Like

No, outside of the function you can get the value of x. Try it and see.

1 Like

when i checked the response it says 200 and when i set the error to a button it says undefined… am i getting error ?

That’s the right blocks to work with WebAPI

%D0%B8%D0%B7%D0%BE%D0%B1%D1%80%D0%B0%D0%B6%D0%B5%D0%BD%D0%B8%D0%B5

2 Likes

I tried earlier, It didn’t work… :confused:

@Tijender_Singh I will show you blocks after 10 mins, I am having food right now :slightly_smiling_face:

I’ll catch here soon :blush:

1 Like

I would be very glad to welcome your blocks! :cowboy_hat_face:

2 Likes

thanks kartik

1 Like

hello is not printed and also getting no data in label5