You're Browsing As A Guest! Register Now... |
||
|
Become a VB.NET Expert!
Join 416,720 VB.NET Programmers for FREE! Get instant access to thousands
of VB.NET experts, tutorials, code snippets, and more! There are 2,850 people online right now.Registration is fast and FREE... Join Now!
|
||
how to view pdf file in vb.net?
#4
Re: how to view pdf file in vb.net?
Posted 30 November 2008 - 08:36 AM
#6
Re: how to view pdf file in vb.net?
Posted 01 December 2008 - 03:49 AM
kasbaba, on 30 Nov, 2008 - 01:28 PM, said:
you can also use a webbrowser control...add it to your form and then use the Navigate method...
myWebbrowser.navigate("d:\test.pdf")
this will open the pdf file inside your form...
hope this helps..
kasbaba
well, this is not exactly i expecting to do. i m expecting to do the pdf open by using button clicking function in menu item
File>Open>browse to targeted pdf file
#8
Re: how to view pdf file in vb.net?
Posted 01 December 2008 - 08:25 AM
I hope you were able to get it done.
However, incase you weren't able to do it then here is some code.....
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim Response As DialogResult OpenFileDialog1.FileName = "" OpenFileDialog1.Filter = "PDF Files(*.pdf)|*.pdf|All Files(*.*)|*.*" Response = OpenFileDialog1.ShowDialog() If Response <> Windows.Forms.DialogResult.Cancel Then If OpenFileDialog1.FileName <> "" Then WebBrowser1.Navigate(OpenFileDialog1.FileName) End If End If End Sub
kasbaba
#9
Re: how to view pdf file in vb.net?
Posted 01 December 2008 - 08:48 AM
kasbaba, on 1 Dec, 2008 - 08:25 AM, said:
I hope you were able to get it done.
However, incase you weren't able to do it then here is some code.....
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim Response As DialogResult OpenFileDialog1.FileName = "" OpenFileDialog1.Filter = "PDF Files(*.pdf)|*.pdf|All Files(*.*)|*.*" Response = OpenFileDialog1.ShowDialog() If Response <> Windows.Forms.DialogResult.Cancel Then If OpenFileDialog1.FileName <> "" Then WebBrowser1.Navigate(OpenFileDialog1.FileName) End If End If End Sub
kasbaba
this is wat i m expecting to...thx a lot......
now i m proceeding to other button function for my application...
i wan to have a button tat perform the function of zoom in and zoom out function to the displayed pdf document.
i have an idea is to change the current page size from A3 to A5 for zoom out etc...not sure hw to implement in . NET
Bort, on 1 Dec, 2008 - 05:57 AM, said:
thx a lot...i got it..
#10
Re: how to view pdf file in vb.net?
Posted 01 December 2008 - 12:28 PM
Right Click on Toolbox>Choose Items...>COM Components>Acrobat PDF Reader
Put a Acrobat PDF Reader control on your form and call PDFControlName.LoadFile() to open a PDF from your code and PDFControlName.setZoom() to zoom the document.
#11
Re: how to view pdf file in vb.net?
Posted 01 December 2008 - 07:41 PM
magicmonkey, on 1 Dec, 2008 - 12:28 PM, said:
Right Click on Toolbox>Choose Items...>COM Components>Acrobat PDF Reader
Put a Acrobat PDF Reader control on your form and call PDFControlName.LoadFile() to open a PDF from your code and PDFControlName.setZoom() to zoom the document.
hi thr, from this method, if i am generated a executable file program. since i m using the Acrobat PDF Reader library, is it this will cause my executed program in error if it couldnt found the library in the particular location?
#12
Re: how to view pdf file in vb.net?
Posted 02 December 2008 - 05:43 AM
#13
Re: how to view pdf file in vb.net?
Posted 07 December 2008 - 12:45 AM
magicmonkey, on 2 Dec, 2008 - 05:43 AM, said:
I had been using the dynamic library provided by pdfnet for my pdf document reader, now i am able to view the pdf files and add on the basic functions of a document reader.
now i have an issue, i am able to generate a .exe file for my application but it cant work properly without the .dll library file in the same path and the resource file as well, it there any way that make all of that into a single file? instead of i need to carry 3 files together to run my application well.
#15
Re: how to view pdf file in vb.net?
Posted 07 December 2008 - 09:19 AM
magicmonkey, on 7 Dec, 2008 - 07:48 AM, said:
hi there, i got the ILMerge.exe utility, but i have no idea how will it works to merge the files....


Reply





MultiQuote







|