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

  • SEARCH
  • Home
  • 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 6945787
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T13:28:50+00:00 2026-05-27T13:28:50+00:00

I am using silverlight4 app ,i have a requirement like to store the word/pdf

  • 0

I am using silverlight4 app ,i have a requirement like to store the word/pdf file in the database(sqlserver) and successfully i did that and now i want to open the stored file using the corresponding application with my extension.Iam not using OOB ,it that possible to open the file or to store the file in a user selected location.Can anyone plz help me on this?

Thanks in advance.

  • 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-05-27T13:28:51+00:00Added an answer on May 27, 2026 at 1:28 pm

    I would suggest create one .aspx page or HTTPHandler then override ProcessRequest method.

    public void ProcessRequest(HttpContext context)
    {
       //database table or PDF/word file
       System.IO.MemoryStream mstream = GetData(); 
       //Convert the memorystream to an array of bytes. 
       byte[] byteArray = mstream.ToArray();         
    
        string fileName= "test.pdf";
        context.Response.Clear();
    
        context.Response.AppendHeader("content-disposition", "attachment; filename=" + fileName);
        context.Response.ContentType = "application/octet-stream";
        context.Response.BinaryWrite(byteArray); 
        context.Response.Flush();
        context.Response.End();
    }
    

    Your Silverlight application will act just like normal client and makes http Request using

    <HyperlinkButton Content="Click Me" NavigateUri="Download.aspx?id=fileid" />
    

    in above code

      context.Response.AppendHeader("content-disposition", "attachment;
    

    tells browser to prompt for OPEn/Save dialog.

    I hope this will work.

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

Sidebar

Related Questions

I have a .NET 2.0 app (using C#) that shows some dynamically constructed HTML
I have a Silverlight 4 app which pulls entities down from a database using
I have a scribbale inkpresenter in my silverlight app that I'm using multiple times
I have a few users that are using a silverlight app that aren't recieving
I have created a silverlight app that consits of like buttons within specific usercontrols
I'm writing a Silverlight app using the MVVM pattern. I have a main view
I am developing a Silverlight app using VS2008 Express. I have just implemented a
I have a database that consists of 5 tables : Course, Category, Location, CourseCategories,
I have a silverlight app using Prism practices; the current code does a search
I am developing a web app using silverlight. I read that Microsoft offers 10

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.