Android : android:pathPattern for single file

on Tuesday, September 2, 2014


I need to define IntentFilter for single file named myfile.ext. At the moment my manifest looks like:



<intent-filter>
<action android:name="android.intent.action.VIEW" />
<action android:name="android.intent.action.EDIT" />
<category android:name="android.intent.category.DEFAULT" />
<data
android:scheme="file"
android:mimeType="*/*"
android:host="*"
android:pathPattern=".*\\myfile\\.ext"
/>
</intent-filter>


I have also tried other variants like: android:pathPattern=".*\\myfile.ext" and so on - but still it doesn't handle my file.


Any clues?


0 comments:

Post a Comment