How do I use MIT app inventor's background task extension which helps the app to run in background?

How to use MIT app inventor's background task extension which helps the app to run in background.
As i want, just a function to run in background.
Can you guide me how to do this easily.

That extension is discontinued...
Try this

Taifun

so please tell me how to use this easily

Why not try something, then come back here if you get stuck. Read the documentation supplied with the extension and read the comments of other developers experiences with the extension.

1 Like

actually i am not getting how to,
can you please give me a sample code for calling a function

What exactly do you want to run in background?

a function which will get the data from firebase and if the data is something then a notification will come.

Likewise, I need to pull data in the background with the airtable, I need to send a notification when the data changes, but I tried every version of the extension, but none of them worked!

image

You cannot use Firebase extension with Itoo, since a procedure will be called in background, the only way to interact with components are with the blocks, and you cannot set "FirebaseToken" by blocks, its hidden. You can try out alternatively by using an firebase extension.


I guess you are talking about the Old Background Tasks Extension, that is maintained nomore, you have to use the more reliable Itoo Extension instead.

so can we use tiny db


please show how to pull data from airtable in background

Yeah, you can use Tiny DB.


Are you using an extension to pull data from Airtable? If yes, which one? I dont see it there.

this extension please help

Okay, so here is how you need to do it:

  • First set all the Airtable credentials through the property blocks, the sheet name, API key etc.

  • Then, suppose you want to use the GotCell block. First you need to register the event "GotCell" through the RegisterEvent block, like "AirtableClassic1.GotCell", and supply a function name, the function provided will have the same arguments as the event.

image

  • Then you would normally call the "GotCell" block, and it would trigger the corresponding procedure registered after getting the data of the cell.


so how to get the value i call in background

can you please tell me about a fiebase extension

DSOMonitor (1).aia (29.2 KB)

Can this code get message in background and show it on the label.

Unfortunately, I dont not know the extension you are using.
The next step you have to do is to create a procedure which the numbers of arguments the "GotCell" has.

image

Here is the example of the Timer event in clock.


Please post your blocks, what have you tried so far?

Actually I was trying to get message and store it in a variable and when the app will open then the message will be shown on the label
But it didn't worked!