2011-08-12 62 views

回答

0

如果你可以使用Air3.0,創建一個原生擴展,並調用Java函數與此代碼

摘自:http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/content/ExternalStorage.html

// Tell the media scanner about the new file so that it is 
// immediately available to the user. 
MediaScannerConnection.scanFile(this,new String[] { file.toString() }, null, 
new MediaScannerConnection.OnScanCompletedListener() { 
public void onScanCompleted(String path, Uri uri) { 
Log.i("ExternalStorage", "Scanned " + path + ":"); 
Log.i("ExternalStorage", "-> uri=" + uri); 
} 
});