473,405 Members | 2,445 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Display And Embed PDF in the browser

12
Coding in vb, framework .net 2.0, vs2005

When an user want to click on to view the report which is in the .pdf format,
I will be able to display the file and embed it in the browser.

What codes should i include?
Aug 14 '08 #1
14 9772
Curtis Rutland
3,256 Expert 2GB
Well, if they have the proper reader installed, you can just link to the PDF. It will be displayed in the embedded PDF reader.
Aug 14 '08 #2
phoenie
12
Well, if they have the proper reader installed, you can just link to the PDF. It will be displayed in the embedded PDF reader.
i am sorry...i cant catch what you mean...what is the "proper reader" u meant?
can give some examples?

well...i want to display the pdf file in browser, but not open the pdf file like using Adobe...example as link below:

http://www.beansoftware.com/ASP.NET-Tutorials/PDF-View-Custom-Control.aspx

but unfortunately i cannot run the program successfully...
there have some problem on the library...

thanx...
Aug 14 '08 #3
Curtis Rutland
3,256 Expert 2GB
Well, I meant Adobe Reader. Maybe somebody else knows more. Did you try to follow the tutorial you linked step by step?
Aug 14 '08 #4
phoenie
12
Well, I meant Adobe Reader. Maybe somebody else knows more. Did you try to follow the tutorial you linked step by step?
Yes...i do follow the tutorial step by step, debug it line by line...
that why only figure out the ShowPDF.dll is refer to the C:\\Scott.....

By the way...
I've tried other method...
When i try to add the reference named acrobat.dll in my project
but my toolbox do not appear its components...
do you have any idea what going wrong?
Aug 14 '08 #5
Curtis Rutland
3,256 Expert 2GB
I don't have access to my test PC right now (stuck on my mac right now) but check in tomorrow, I should be able to help once I get my PC set up again.

The general idea is that you don't need to add a reference, you need to right click in the toolbox and choose components, and look through the COM objects to find Adobe Reader.
Aug 14 '08 #6
phoenie
12
I don't have access to my test PC right now (stuck on my mac right now) but check in tomorrow, I should be able to help once I get my PC set up again.

The general idea is that you don't need to add a reference, you need to right click in the toolbox and choose components, and look through the COM objects to find Adobe Reader.
Really million thanx for your help....

I've tried "dig through" the toolbox,
still cant find any components for AdobeReader
Aug 14 '08 #7
DrBunchman
979 Expert 512MB
Not sure if I'm missing the point here but if the client machine has at least got Adobe Reader installed then you can use the <iframe/> tag to embed a pdf can't you?
Expand|Select|Wrap|Line Numbers
  1. <iframe src="PDFDirectory/Test.pdf"></iframe>
Just set up PDFDirectory as a virtual directory in your IIS and you should be able to point to it as above.

Hope this helps,

Dr B
Aug 14 '08 #8
phoenie
12
Not sure if I'm missing the point here but if the client machine has at least got Adobe Reader installed then you can use the <iframe/> tag to embed a pdf can't you?
Expand|Select|Wrap|Line Numbers
  1. <iframe src="PDFDirectory/Test.pdf"></iframe>
Just set up PDFDirectory as a virtual directory in your IIS and you should be able to point to it as above.

Hope this helps,

Dr B
thanx for your input...
But now I do not have virtual directory yet...
So what should I do?
(I am sorry...I am a newbie..so may be lot easy question cant understand by me)
Aug 14 '08 #9
DrBunchman
979 Expert 512MB
Sorry phoenie, ignore the part about virtual directories for now.

Just put the unc of the pdf into the src property of the iframe tag and it should embed. e.g.
Expand|Select|Wrap|Line Numbers
  1. <iframe src="\\servername\sharename\folder\test.pdf" height="100" width="200"></iframe>
Hope this helps,

Dr B
Aug 14 '08 #10
phoenie
12
Thanx again for your helping hand...

I've tried on your codes...
It really helped me...

now the next step I need to do is:
How to disable the print icon in the Adobe reader when displaying the .pdf file?
Aug 15 '08 #11
Plater
7,872 Expert 4TB
How to disable the print icon in the Adobe reader when displaying the .pdf file?
The availablitiy of the print button in a pdf file is a security property in the PDF file itself. If you want the button disabled, you will need to generate the pdf with the correct security settings.
You should take note though that just because you set that security feature, does not mean that pdf readers have to abide by it.
Aug 15 '08 #12
DrBunchman
979 Expert 512MB
As I mentioned in another thread recently, if you are concerned about people 'stealing' your pdf's then you should consider watermarking them or reducing the resolution so they are only suitable for previews.

Dr B
Aug 15 '08 #13
phoenie
12
The availablitiy of the print button in a pdf file is a security property in the PDF file itself. If you want the button disabled, you will need to generate the pdf with the correct security settings.
You should take note though that just because you set that security feature, does not mean that pdf readers have to abide by it.
what are the security features that I need to set?
thanx in advance
Aug 18 '08 #14
phoenie
12
As I mentioned in another thread recently, if you are concerned about people 'stealing' your pdf's then you should consider watermarking them or reducing the resolution so they are only suitable for previews.

Dr B
Em...this requirement is request by the client...
The system need user to log in before using it...
then will keep track the log in id to see the user has the privillege to print it...
maybe we cant prevent from others to print down the document...
but at least can make a little control telling that user he/she does not has the right to print...

ya...i jz have another thinking...
convert the pdf file to TIFF file
since the file only has 2 types, TIFF and pdf
is it a good idea?possible?
Aug 18 '08 #15

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Wolfgang Schwanke | last post by:
Dear usenet, I'm having the following small problem. I've been ask to add some Quicktime panoramas to a website. The author of the panoramas has made two versions of each: One in MOV format,...
11
by: Anna | last post by:
Hi all. I want to embed the EMBED tag in the object tag. I understood that I need to provide a PARAM tag inside the OBJECT whose value will hold the content of EMBED src attribute, but after...
2
by: chaitatp | last post by:
Hi guys, I have posted a similar question before but this post has some different. The similar link is: ...
2
by: tale | last post by:
Does anybody know if it is possible for me to display a web page from within my windows application when using No Touch Deployment. Currently, we do almost everything in the windows client. ...
3
by: Tin Man | last post by:
I have an aspx page: myPage.aspx that I want to always display in a new brower window regardless of how it gets invoked i.e. hyperlink, response.redirect, server.transfer. Is there something I can...
4
by: yawnmoth | last post by:
I'm currious - how do applet, object, and embed compare to one another? They seem to me to mostly do the same thing, so why would one chose one over another?
1
by: Joe | last post by:
Hi I am able to embed Excel into a WebBrowser on my Dev machine but on a client machine an instance of Excel starts in it's own window. Anyone seen this before??? Thanks
2
by: John | last post by:
I have CSS drop down navigatoon bar and it works fine. However, when I have page where I have an <embed - needed to show a PDF file, such as: <embed src="Security.pdf" width="900"...
3
by: =?Utf-8?B?SG93IHRvIGVtYmVkIGEgQnJvd3Nlci4uLi4uLi4u | last post by:
How can i embed a web browser in an IE page?
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.