List Info

Thread: using ASP.NET 2.0, C# and Sql 2005...




using ASP.NET 2.0, C# and Sql 2005...
user name
2007-01-06 15:13:57
Hi,
    I am stuck in one problem. The scenerio is as follows
  1. I have a table in Sql server 2005 (to store files). I store .html and .htm files ;using Image datatype.
  2. From the FrontEnd, first i upload a .htm/.html file using upload control  (ASP.NET and C#)
  3. ( <input type="file" id="btnBrowseH" runat="server" /> )
  4. Code to save the uploaded file using C# is
  5. HttpPostedFile myFile = btnBrowseH.PostedFile;
    int nFileLen = myFile.ContentLength;
    byte[] content = new byte[nFileLen];
  6. Now, we can pass this content to the stored procedure to save it.
  7. The file saves perfectly in Image column as bytes.
  8. My requirement is to have a button. And on click of this button i should fetch the file back and open it up in the "new instance of the browser".
  9. This part is very much important that it has to be displayed in the new instance of the browser because if it opens in the current instance then the application from which it is called will be overwritten. Then on pressing Back the application will be reloaded.
If you any idea, code etc then please let me know. This is the only part left in my schedule.
 
Regards
Teju

2;__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com __._,_.___ __,_._,___

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )