我正在使用FoxitRDK框架在我的應用程序中打開PDF文檔。在演示中,除了一件事情之外,一切正常:我無法點擊超鏈接。我已經通過SDK文檔和框架內的類,但無法罰款解決方案。FoxitIOSRDK:無法點擊超鏈接
文檔鏈接低於:
http://www.foxitsdk.com/docs/mobile-pdf-sdk/developer_guide_ios.pdf
,這裏是我的代碼
NSString* pdfPath = [[NSBundle mainBundle] pathForResource:@"getting_started_ios1" ofType:@"pdf"];
// Initialize a PDFDoc object with the path to the PDF file
FSPDFDoc* pdfdoc = [FSPDFDoc createFromFilePath:pdfPath];
// Initialize a FSPDFViewCtrl object with the size of the entire screen
pdfViewCtrl = [[FSPDFViewCtrl alloc] initWithFrame: CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height-60)];
[pdfViewCtrl registerDocEventListener:self];
[pdfViewCtrl registerPageEventListener:self];
[pdfViewCtrl registerGestureEventListener:self];
// Set the document to display
[pdfViewCtrl setDoc:pdfdoc];
// Add the pdfViewCtrl to the root view
[self.view addSubview:pdfViewCtrl];
extensionsManager= [[UIExtensionsManager alloc]initWithPDFViewControl:pdfViewCtrl];
pdfViewCtrl.extensionsManager = extensionsManager;
[extensionsManager registerAnnotEventListener:self];
[extensionsManager registerAnnotHandler:self];
//Search button
searchButton = [[UIButton alloc] initWithFrame:CGRectMake(280, 80, 80, 40)];
[searchButton setBackgroundColor:[UIColor grayColor]];
[searchButton setTitle: @"Search" forState: UIControlStateNormal];
[searchButton addTarget:self action:@selector(showSearchBar)
forControlEvents:UIControlEventTouchUpInside];
[self.view addSubview:searchButton];
我該如何解決這個問題?
我已編輯我的問題.even在演示代碼中不起作用 – guru
[pdfViewCtrl gotoPage:3 animated:true];需要在onDocOpened事件中調用。 –
謝謝艾米,但我的問題是不同的相關超鏈接 – guru