• Post Reply Bookmark Topic Watch Topic
  • New Topic

Issue with response.setCOntentType and IE  RSS feed

 
sunilkumar ssuparasmul
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all ,


response.setContentType("application/msword");
response.setHeader("Content-disposition","inline; filename=test.doc");
o = response.getOutputStream();
o.println("<html>");
o.println("<head>");
o.println("<title>Runtime Model Structure</title>");
o.println("</head>");
o.println("<body>");
o.println("<h3>Runtime Model Structure</h3>");
o.println( generateConetentToDIsplay());
o.println("</body>");
o.println("</html>");

I have the above code in my program , it works perfectly in IE6 with SP1 and win2000 and it opens a word doc with the above content , where as the same code i try in WIN XP and IE6 with SP2 , the window opwns and just closes it .

Please let me know if i am missing something

Regards
Sunil.s
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found IE a buggy browser sometimes and have similar views for windows too. So, can you try some other machine with same specs. I mean WinXP and IE 6.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!