on 10-18-2005 6:32 AM
Hello,
In my BSP application a PDF document opens on a button click. However, the PDF seems to work on some machines and not on others. This is mainly in production.
Can you please provide any suggestion for why it is behaving as such?
My answer may look silly but are you sure that those machines where its not openning is installed with adobe acrobat reader?
<i>However, the PDF seems to work on some machines and not on others</i>
Can you tell us what exactly is happenning?
Regards
Raja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
My initial thought would be that the pdf extension (I hope that you provide the pdf extension, MIE needs it) isn't linked to AR.
Check http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/win_fcab_reg_filetype... for this.
If you have eg Mozilla, check this http://www.mozilla.org/docs/end-user/helper-applications.html
If that's not the case, I would add this in your BSP page that generates the PDF:
runtime->server->response->set_header_field( name = 'Content-Length'
value = contentsize ).
runtime->server->response->delete_header_field( name = 'Cache-Control' ).
runtime->server->response->delete_header_field( name = 'Expires' ).
runtime->server->response->delete_header_field( name = 'Pragma' ).
runtime->server->response->set_header_field( name = 'Content-Type'
value = 'application/pdf' ).
Eddy
Hi Eddy,
can you please explain me the steps specified by you ?
runtime->server->response->set_header_field( name = 'Content-Length'
value = contentsize ).
runtime->server->response->delete_header_field( name = 'Cache-Control' ).
runtime->server->response->delete_header_field( name = 'Expires' ).
runtime->server->response->delete_header_field( name = 'Pragma' ).
runtime->server->response->set_header_field( name = 'Content-Type'
value = 'application/pdf' ).
however I am using the first and the last line already in the code
Hi,
First some background info. We always need to be cross-browser and croos-platform. We found out that all different type of browsers have different behaviour.
runtime->server->response->set_header_field( name = 'Content-Length'
value = contentsize ). is rather obvious, we set the langth of the file.
runtime->server->response->delete_header_field( name = 'Cache-Control' ).
runtime->server->response->delete_header_field( name = 'Expires' ).
runtime->server->response->delete_header_field( name = 'Pragma' ).
have all the same purpose: deleting everything which in the browser (cache).
See also 14.9 in http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html
runtime->server->response->set_header_field( name = 'Content-Type'
value = 'application/pdf' ). is rather obvious too.
Eddy
Hi vaibhav,
You can learn more about this from the weblog "BSP Programming: Handling Of Non-HTML Documents" by Brian
<a href="/people/mark.finnern/blog/2003/09/23/bsp-programming-handling-of-non-html-documents:///people/mark.finnern/blog/2003/09/23/bsp-programming-handling-of-non-html-documents
Regards,
Siddhartha
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.