Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8884899
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T21:10:36+00:00 2026-06-14T21:10:36+00:00

Here is the response’s header: HTTP/1.1 200 OK Cache-Control: private Content-Length: 37888 Content-Type: application/octet-stream;

  • 0

Here is the response’s header:

HTTP/1.1 200 OK
Cache-Control: private
Content-Length: 37888
Content-Type: application/octet-stream; charset=utf-8
Server: Microsoft-IIS/7.5
Set-Cookie: ASP.NET_SessionId=g4tidw45yqwztc55nv0zdu55; path=/; HttpOnly
Content-Disposition: attachment; 
**filename=%e5%85%a5%e5%ad%a6%e6%b3%a8%e6%84%8f%e4%ba%8b%e9%a1%b9.doc**
X-AspNet-Version: 2.0.50727
X-Powered-By: ASP.NET
Date: Mon, 26 Nov 2012 06:24:36 GMT

I can get this header via a software called Wireshark.

Here is DownloadManager in Java code:

lastDownloadId = manager.enqueue(new DownloadManager.Request(uri)
            .setAllowedNetworkTypes(
                    DownloadManager.Request.NETWORK_MOBILE
                            | DownloadManager.Request.NETWORK_WIFI)
            .setAllowedOverRoaming(false)
            .setTitle("MyTest")
            .setNotificationVisibility(DownloadManager.Request.VISIBILITY_VISIBLE_NOTIFY_COMPLETED)
            .setDescription("Something Useful")
            .setDestinationInExternalPublicDir(
                    Environment.DIRECTORY_DOWNLOADS, "abc.doc"));

and I want get the header in Java code, so I can get the filename of this response.

How can I do this? Thank you.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T21:10:37+00:00Added an answer on June 14, 2026 at 9:10 pm

    Doesn’t the DownloadManager honour the Content-Disposition header? You can check if the local file names matches the header. If not, you will have to download the file directly with HttpClient or HttpURLConnection.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Here below response send my windows application to my site http://www.abcd.com/response.aspx?name=bala response page i
Here is my response envelope: <s:Envelope xmlns:s=http://schemas.xmlsoap.org/soap/envelope/> <s:Body> <s:Fault> <faultcode>s:Client</faultcode> <faultstring xml:lang=en-US>The creator of
Here is my XML Response: <DIDL-Lite xmlns=urn:schemas-upnp-org:metadata-1-0/DIDL-Lite/ xmlns:dc=http://purl.org/dc/elements/1.1/ xmlns:upnp=urn:schemas-upnp-org:metadata-1-0/upnp/ <item id=1182 parentID=40 restricted=1> <title>Hot
This is a code from my c# web application here [ Response.Write(match.Groups[1]); ] i
I have an HTTP response of HTTP/1.0 200 OK\r\n\r\n <!DOCTYPE html>... Both Firefox and
Here is my response code in jQuery: var response = $.parseJSON(response); for (var i
I posted a related question to no response but here I'll be less narrow.
Here is my method to connect to server and get the response in MyUtilitiesActivity
Here is my code.. string attachment = attachment; filename=Call-Details-Report- + startDate.SelectedDate.Value.ToString(MM-dd-yyyy) + .csv; Response.Clear();
I'm trying to get a JSON response and iterate through the data. Here is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.