English 中文(简体)
非法占有:在打电话下载Rosager.query()时,不得查询当地人名栏。
原标题:IllegalArgumentException: column local_filename is not allowed in queries when calling DownloadManager.query()

a. 在我通过下载下载的Im中:

val downloadId: Long = downloadManager.enqueue(dr)

If user reopenning application, i m checking downloading status via:

fun isDownloadInProgress(): Boolean {
    val dq: DownloadManager.Query = DownloadManager.Query()
    dq.setFilterById(downloadId)
    val cursor: Cursor? = downloadManager.query(dq)
    if (cursor == null || !cursor.moveToFirst()) {
        return false
    }
    val status: Int = cursor.getInt(cursor.getColumnIndex(DownloadManager.COLUMN_STATUS))
    if (status == DownloadManager.STATUS_RUNNING || status == DownloadManager.STATUS_PENDING) {
        return true
    }
    return false
}

有了这部法典,我在小小小米的rash泥中发生了几起坠毁事件,有11和12种。

Caused by java.lang.IllegalArgumentException: column local_filename is not allowed in queries
       at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:172)
       at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:142)
       at android.content.ContentProviderProxy.query(ContentProviderProxy.java:481)
       at android.content.ContentResolver.query(ContentResolver.java:1219)
       at android.content.ContentResolver.query(ContentResolver.java:1151)
       at android.content.ContentResolver.query(ContentResolver.java:1107)
       at android.app.DownloadManager$Query.runQuery(DownloadManager.java:1506)
       at android.app.DownloadManager.query(DownloadManager.java:1736)
       at android.app.DownloadManager.query(DownloadManager.java:1718)

缩略语

中文不译,原文不译。

我的问题是:

  1. If am i using DownloadManager incorrect and there is another way for check download status, can someone suggest how to do this?
  2. If is this a bug on Xiaomi ROM, can someone give me the link on issue?

感谢。

问题回答

感谢分享这一问题。 请提供更多信息,以调查:

1. 模式

2. 罗氏

3. 退学率

4) 如果材料不齐





相关问题
Android - ListView fling gesture triggers context menu

I m relatively new to Android development. I m developing an app with a ListView. I ve followed the info in #1338475 and have my app recognizing the fling gesture, but after the gesture is complete, ...

AsyncTask and error handling on Android

I m converting my code from using Handler to AsyncTask. The latter is great at what it does - asynchronous updates and handling of results in the main UI thread. What s unclear to me is how to handle ...

Android intent filter for a particular file extension?

I want to be able to download a file with a particular extension from the net, and have it passed to my application to deal with it, but I haven t been able to figure out the intent filter. The ...

Android & Web: What is the equivalent style for the web?

I am quite impressed by the workflow I follow when developing Android applications: Define a layout in an xml file and then write all the code in a code-behind style. Is there an equivalent style for ...

TiledLayer equivalent in Android [duplicate]

To draw landscapes, backgrounds with patterns etc, we used TiledLayer in J2ME. Is there an android counterpart for that. Does android provide an option to set such tiled patterns in the layout XML?

Using Repo with Msysgit

When following the Android Open Source Project instructions on installing repo for use with Git, after running the repo init command, I run into this error: /c/Users/Andrew Rabon/bin/repo: line ...

Android "single top" launch mode and onNewIntent method

I read in the Android documentation that by setting my Activity s launchMode property to singleTop OR by adding the FLAG_ACTIVITY_SINGLE_TOP flag to my Intent, that calling startActivity(intent) would ...

From Web Development to Android Development

I have pretty good skills in PHP , Mysql and Javascript for a junior developer. If I wanted to try my hand as Android Development do you think I might find it tough ? Also what new languages would I ...

热门标签