PROFESSIONAL NEWSGROUPS
WINDEV
,
WEBDEV
and
WINDEV Mobile
Home
|
Recent messages
|
Connect
|
Sign out
|
English
Home
→
WINDEV Mobile 2024
→
[WM18] Proposition d'application messagerie sous Androïd
[WM18] Proposition d'application messagerie sous Androïd
Started by DomDom, Jan., 18 2013 11:58 AM - 1 reply
Connect yourself…
DomDom
#1
Registered member
2 messages
Posted on January, 18 2013 - 11:58 AM
Bonjour,
Je développe une petite application permettant de transférer des photos techniques par messagerie en pièce jointe.
L'appli fonctionne très bien mais ne me propose pas tous les clients de messagerie.
La fonction EmailLanceAppli() ne propose que les applications e-mail et Gmail natives de l'appareil, alors que notre société utilise Lotus Traveler.
Pourtant, quand j'affiche la photo dans l'appli Galerie, l'option "Partager" me propose bien Lotus Traveler.
Il doit y avoir un référencement de Lotus Traveler à définir dans le système, mais je n'ai aucune idée de comment faire.
Bien à vous, merci pour votre aide.
Report
0
0
DomDom
#2
Registered member
2 messages
Posted on January, 21 2013 - 11:56 PM
Je réponds à ma propre question :
J'ai créé une procédure globale contenant le code java ci-dessous. Mais attention, pour appeler une procédure java depuis Windev en lui passant un chemin du fichier, le chemin doit commencer par file:///storage et non par /storage comme le renvoie la fonction SysRepCarteStockage()
Par exemple si sous windev ma photo est /storage/sdcard0/MaPhoto.jpg, le chemin qui doit être passé à la fonction est file:///storage/sdcard0/MaPhoto.jpg sinon, les applications Android ne trouvent pas le fichier.
Voici la fonction :
import android.content.Intent;
import android.net.Uri;
import android.app.Activity;
public static void PhotoParMail(String path)
{
Activity act = getActiviteEnCours();
Intent sharingIntent = new Intent(Intent.ACTION_SEND);
Uri screenshotUri = Uri.parse(path);
sharingIntent.setType("image/*");
sharingIntent.putExtra(Intent.EXTRA_STREAM, screenshotUri);
act.startActivity(sharingIntent);
}
Report
0
0
→ Go back to WINDEV Mobile 2024
WINDEV 2024
WEBDEV 2024
WINDEV Mobile 2024
WINDEV (earlier versions)
WEBDEV (earlier versions)
WINDEV Mobile (earlier versions)
Reports & Queries
Off-topic
Tools
Français
English
Español
Portuguesa
Close this window
Search type
Only topics
All the messages
Search period
Any time
Past hour
Past 24 hours
Past week
Past month
Past year
Cancel
Preview of your message
Adding an image
Import an image from a URL
Send an image from a file of your disk
Drop a file or click "Browse..."
or
Cancel
0%
WLanguage
SQL
XML, HTML
JAVA, Javascript
Text