Ciao amante del bel Paese,Ciao a tutti amanti del bel paese,
ho una domanda contorta per voi. Si può creare un app che tramite intent richiama una sub di un'altra mia app?
Grazie
Uhm... è da vedere, perché gli Intent possono contenere dati extra, e quindi potresti metteri il nome della routine da eseguire ed anche i parametri.Ciao amante del bel Paese,
Non si può accedere a una qualunque sub di un'altra App.
Ma se l'app che devi chiamare prevede che tu possa accedere una sua API, come da ad esempio WhatsApp, allora a quel specifico servizio, con gli opportuni metodi, puoi usarlo.
Verrebbe assai complicato inserire la Sub nella nuova app perchè questa Sub fa parecchie cose e usa oggetti presenti nella app richiamata.fai prima ad includere la sub nella "nuova" app, oppure genera una libreria della sub
Used Googletranslate to understand. Sorry for writing in English.Ciao amante del bel Paese,
Non si può accedere a una qualunque sub di un'altra App.
Ma se l'app che devi chiamare prevede che tu possa accedere una sua API, come da ad esempio WhatsApp, allora a quel specifico servizio, con gli opportuni metodi, puoi usarlo.
Nella seconda parte della mia risposta l'ho scritto che è possibile se l'app da chiamare lo prevede. Ho preso come esempio WhatsAppUsed Googletranslate to understand. Sorry for writing in English.
That´s not correct in Total.
You are right you can not just directly use any sub from another App.
But if the app supports a/some Intent(s) which can be used then it is Possible.
Remember this (old but still valid) Tutorial
[TUTORIAL] Inter-app Communication with Intents
DISCLAIMER: This tutorial is written without testing code. There may be bugs, but try to understand the process, not copy the code. An intent is a way for different applications to communicate at run time. It can be used to pass messages between activities and make them do actions. Using...www.b4x.com
The point is that you need to develop both apps to fully Support some communication. Or at least you need to know the possible Intents the calling (or the receiving) App understands.
ps: mettere like è il modo di dire grazie?