With MySword 5.3, it is now possible to link or open MySword from other apps (it was already available in old versions but it is still just experimental).
There are two ways you can link to MySword from other apps: via HTML link or application code. Both require the MySword app installed in your device, of course.
The HTML link is of the form: https://mysword.info/b?r=Psa_37_3-6/ISV or https://mysword.info/b?r=Psa+37:3-6/ISV. In Email as well as in SMS app, the https:// is actually optional as the app can already detect that it is an HTML hyperlink. Valid verse formats are:
- No specific Bible translation like: mysword.info/b?r=Psa_37_3-6
- Single verse like: mysword.info/b?r=Psa_37_3
- Numeric format like: mysword.info/b?r=19.37.3-6
The + in URLs is actually the encoded form of space.
When you tap the link and the Select dialog shows up, you can choose MySword for Android as the Default app because the URL is only specific to MySword.
For programmers, you can open MySword in a similar way by using the following code:
try { Intent intent = new Intent(); intent.setComponent(ComponentName.unflattenFromString( "com.riversoft.android.mysword/com.riversoft.android.mysword.MySwordLink")); intent.setData(Uri.parse("https://mysword.info/b?r=Joh_3_16")); startActivity(intent); } catch (Exception e) { //showAlert("Error", e.getLocalizedMessage()); }
The above method does not use the generic Intent.ACTION_VIEW one so there is no more Select dialog that will show up but MySword will automatically open.
Note that for both cases, the normal MySword app if running is not affected as the MySword pop up that will open is a separate special screen. When you tap the Full MySword button, a separate MySword instance will be opened that will not save navigation history and so not affecting the normal instance.
Enjoy using MySword and linking to MySword!