# How to determine when a message has been sent?

**URL:** <https://community.thunkable.com/t/how-to-determine-when-a-message-has-been-sent/379593>\
**Category:** Questions about Thunkable X\
**Created:** [December 23, 2019, 8:22pm UTC](https://community.thunkable.com/t/how-to-determine-when-a-message-has-been-sent/379593 "2019-12-23T20:22:48Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [December 23, 2019, 8:22pm UTC](https://community.thunkable.com/t/how-to-determine-when-a-message-has-been-sent/379593/1 "2019-12-23T20:22:48Z")

</div>

I know that there’s probably no way to know when a user has actually sent an SMS text message from a Thunkable app but I’m hoping someone has a suggestion for a way to figure that out.

When I use the In—\>Share—\>SendTextMessage block, it opens the default messaging service on the phone. If the user sends a message, it then switches back to the Thunkable app. What if I had a timer running and right before I call SendTextMessage, I change a variable value from false to true (e.g. OpenedSMS=true) and store the value of the timer. Then, I have a block that constantly checks to see if OpenedSMS is true AND the current timer value is the same as the stored value… or say, 1 second greater. That way, I know that the app switched to an SMS app and switched back since only a second or so has elapses.

Would that work? I would test it myself but I can’t get a simple count up timer to work. Can someone share a screenshot of a working count up timer? I’ve looked through the forums and so far haven’t found one from Thunkable X that just displays a timer that counts up each second.

---

<div class="post-metadata">

**Author:** ![domhnallohanlon](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/domhnallohanlon/32/29554_2.png) [@domhnallohanlon](https://community.thunkable.com/u/domhnallohanlon)\
**Post date:** [December 23, 2019, 8:50pm UTC](https://community.thunkable.com/t/how-to-determine-when-a-message-has-been-sent/379593/2 "2019-12-23T20:50:32Z")

</div>

You could even just use the device blocks to log the time stamp of when the SendTextMessage function is called?

It’s not perfect, but would work perfectly well for a proof of concept @tatiang!

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [December 23, 2019, 10:24pm UTC](https://community.thunkable.com/t/how-to-determine-when-a-message-has-been-sent/379593/3 "2019-12-23T22:24:01Z")

</div>

I thought of that first but the problem is that I don’t know when they resume from sending a message and the time stamp would keep updating while they are in the SMS app. So I don’t think I could rely on that. I need a value that pauses when the app is in the background.

On second thought, maybe it would work. I want to be able to display an alert that shows the message they send (which I store in a variable) _after_ they send it.

---

<div class="post-metadata">

**Author:** ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)\
**Post date:** [November 8, 2024, 11:46am UTC](https://community.thunkable.com/t/how-to-determine-when-a-message-has-been-sent/379593/4 "2024-11-08T11:46:19Z")

</div>


