Reputation: 35
I have stucking in my application. I have developing a pdf viewer application. I creating windows application with .net 3.5. In this application I have taken axacropdf control and took hyperlink 1 to 10 as page number. Now I want to show pdf file with that page inside axacropdf control when I click the particular page number hyperlink. for example I have pdf file with 10 pages. I have list of all pages like
Navigate to Page 1 Navigate to Page 2 Navigate to Page 3 Navigate to Page 4 Navigate to Page 5 .................. etc.
Now when I click on hyperlink Navigate to Page 5 the pdf file open with page 5 in axacropdf file. Here is the code:
//create process to open pdf file Process myprocess = new Process(); myprocess.StartInfo.FileName = "AcroRd32.exe"; myprocess.StartInfo.Arguments = "/A \"page=" + y + "\" " + txtFileName.Text + " "; myprocess.Start();
I have googled about this but I found only open the pdf file with particular page outside of the application through process class. But I want to open this pdf file in adobe pdf reader (axacropdf) control in c#.
Please give me suggestion or code.
Thanks
Upvotes: 0
Views: 3659
Reputation: 6971
I would use this API Ref
its going to be much easier they even have a method called SetCurrentPage on page 113 hope that helps.
Upvotes: 2