# Web preview ok apk not ok

**URL:** <https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690>\
**Category:** Questions about Thunkable X\
**Created:** [December 6, 2021, 12:07pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690 "2021-12-06T12:07:11Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 12:07pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/1 "2021-12-06T12:07:11Z")

</div>

hi  
I don’t understand after trying my application so many times in web preview mode  
I create an apk and it doesn’t work from the login page made with data stored in google sheet

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 12:08pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/2 "2021-12-06T12:08:24Z")

</div>

I didn’t get what you mean. Can you explain more?

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 12:17pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/3 "2021-12-06T12:17:20Z")

</div>

hi

I use my application in preview mode on my pc and on my phone  
it works  
on the other hand, when I make an apk that I download to the phone, it doesn’t work  
my first screen is a login screen and I can’t connect any user to the same users I managed to connect in preview mode use my application in preview mode on my pc and on my phone  
it works  
on the other hand, when I make an apk that I download to the phone, it doesn’t work  
my first screen is a login screen and I can’t connect any user to the same users I managed to connect in preview mode

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 12:19pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/4 "2021-12-06T12:19:16Z")

</div>

Are you using `stored variables`?

If yes, have you initialized them properly?

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 12:21pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/5 "2021-12-06T12:21:01Z")

</div>

in my login screen i use only app variables

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 12:24pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/6 "2021-12-06T12:24:23Z")

</div>

In this case, I can only give you advices after seeing your login screen blocks.

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 12:37pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/7 "2021-12-06T12:37:19Z")

</div>

my initialization sequence is long and not very elegant

 ![Capture d’écran 2021-12-06 à 13.36.09](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/b/1/b1b483ba7b23c1ebdbc40c0a95b524f89bbb7a3b.jpeg)

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 12:43pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/8 "2021-12-06T12:43:56Z")

</div>

Is your Google sheet **shared** or not?

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 12:49pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/9 "2021-12-06T12:49:35Z")

</div>

it is not

update

after sharing?

it works  
: o)

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 12:52pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/10 "2021-12-06T12:52:13Z")

</div>

Can you share it and make sure you select **anyone with the link** and try the APK?

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 1:04pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/11 "2021-12-06T13:04:44Z")

</div>

it’s true, however, it works even in preview mode to connect a user I have to do it twice when the email and password are correct

more the create row blocks do not seem to work all the time I have to think about replacing them with a script of preference according to you?

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 1:16pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/12 "2021-12-06T13:16:18Z")

</div>

> [@bibbi](#):
>
> it works even in preview mode

Yes, because `Preview mode` is part of the browser and you are logged in to the browser by your Google mail this is why it works.

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 1:22pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/13 "2021-12-06T13:22:49Z")

</div>

I think I understood this aspect, however, what I find surprising is that I have to re-enter the identifiers several times it does not work the first time when the identifiers are correct

here are the blocks that manage the connection:

 ![Capture d’écran 2021-12-06 à 14.27.02](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/c/0/c03e539e61eebc8fc63894bcbaca7cc2c9ac5de0.jpeg)

at the first connection, users must change their password which is initially “default”

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 1:37pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/14 "2021-12-06T13:37:30Z")

</div>

If the email is unique in the table then the blocks work but they do extra work for no reason.

Just imagine if you have 50 users and the user signing in is No. 2, the loop will find the correct email and password in the second round but will continue going round and round for all users in the table.

What is the code in `Screen6` that changes the **default** password and where does it go afterwards?

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 1:41pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/15 "2021-12-06T13:41:08Z")

</div>

every user has is own email witch is unique

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 1:43pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/16 "2021-12-06T13:43:29Z")

</div>

So, when you find the correct email `Exit from the loop`.  
 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/0/6/0685829c5ba3701e338262bdaa9b891487bbb223.png)

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 1:45pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/17 "2021-12-06T13:45:32Z")

</div>

the process does not exit the loop when it finds the right email?

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 6, 2021, 1:46pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/18 "2021-12-06T13:46:19Z")

</div>

> [@bibbi](#):
>
> the process does not exit the loop

No.  
It will continue in the background.

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 2:39pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/19 "2021-12-06T14:39:18Z")

</div>

it’s not that yet  
I have to reconsider my login page

---

<div class="post-metadata">

**Author:** ![bibbi](https://avatars.discourse-cdn.com/v4/letter/b/db5fbb/32.png) [@bibbi](https://community.thunkable.com/u/bibbi)\
**Post date:** [December 6, 2021, 3:58pm UTC](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690/20 "2021-12-06T15:58:07Z")

</div>

nothing goes

I don’t get out of this loop

I compare the entered email to the long list of emails to extract the user id and I have to press the button several times to achieve my ends

[Next page](https://community.thunkable.com/t/web-preview-ok-apk-not-ok/1647690.md?page=2)
