如何查看pdf viewer是否打开了pdf文件? [英] How to check pdf viewer opened pdf file or not ?

查看:589
本文介绍了如何查看pdf viewer是否打开了pdf文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hai

在我的Windows应用程序中,我将使用PDF-XChnage Viewer ActiveX Control,我将在下面调用



 调用 PDFxDoc.SetDevInfo(  XXXX -XXXX-XXXX-XXXX-XXXX-XXXX  XXXX $ XXXX $ XXXXXXX_XXXXXXX#

PDFxDoc.OpenDocument(System.Windows.Forms.Application.StartupPath& \ Temp \ + fname)





它也会打开pdf文件,但是我需要检查PDFXDoc控件是否有打开文件?

如果是pdf控件打开文档我将使用以下代码关闭



 PDFxDoc.CloseDocument( 0 





但即使文件没有打开,我也会尝试clo se文件使用PDFxDoc.CloseDocument(0),它会显示错误。



所以我需要检查第一个文件是否打开?所以请告诉我在关闭前如何检查pdf控件是否有文档。



注意:需要办理入住手续是否有条件



 < span class =code-keyword>如果(PDFxDoc)那么 ' 这里需要检查pdf控件是否有文件?如何查看? 

PDFxDoc.CloseDocument( 0 ' 此行关闭文档

否则

EndIF





请尽快回复



问候

Aravind

解决方案

XXXX


XXXXXXX_XXXXXXX# )

PDFxDoc.OpenDocument(System.Windows.Forms.Application.StartupPath& \Temp \ + fname)





它将打开pdf文件另外,但是我需要检查PDFXDoc控件是否有打开文件?

如果是pdf控件打开文档我将使用以下代码关闭



 PDFxDoc.CloseDocument( 0 





但即使文档未打开,我也会尝试使用PDFxDoc.CloseDocument(0)关闭文档,它会显示错误。



所以我需要检查第一个文件是否开放?所以请告诉我在关闭前如何检查pdf控件是否有文档。



注意:需要办理入住手续是否有条件



 < span class =code-keyword>如果(PDFxDoc)那么 ' 这里需要检查pdf控件是否有文件?如何查看? 

PDFxDoc.CloseDocument( 0 ' 此行关闭文档

否则

EndIF





请尽快回复



问候

Aravind


这似乎是公司的一个问题写了ActiveX ...

http://www.tracker-software.com/product/pdf-xchange- viewer-activex-sdk [ ^ ]

Hai
In my windows application i will use PDF-XChnage Viewer ActiveX Control and i will call like below

Call PDFxDoc.SetDevInfo("XXXX-XXXX-XXXX-XXXX-XXXX-XXXX", "XXXX$XXXX$XXXXXXX_XXXXXXX#")

PDFxDoc.OpenDocument(System.Windows.Forms.Application.StartupPath & "\Temp\" + fname)



and it will open pdf document also,but i need to check PDFXDoc control have open document or not ?
if it is document is opened in pdf control i will close using following code

PDFxDoc.CloseDocument(0)



but even though document is not open then i will try to close document using PDFxDoc.CloseDocument(0) ,it will show error.

So i need to check first document is open or not ? so pls tell me how check pdf control have document or not before going to close.

Note: Need to check in if condition like

If(PDFxDoc) Then 'Here need to check pdf control have document or not ? how to check here ??

PDFxDoc.CloseDocument(0)'This line close document

Else

EndIF



Pls reply asap

Regards
Aravind

解决方案

XXXX


XXXXXXX_XXXXXXX#") PDFxDoc.OpenDocument(System.Windows.Forms.Application.StartupPath & "\Temp\" + fname)



and it will open pdf document also,but i need to check PDFXDoc control have open document or not ?
if it is document is opened in pdf control i will close using following code

PDFxDoc.CloseDocument(0)



but even though document is not open then i will try to close document using PDFxDoc.CloseDocument(0) ,it will show error.

So i need to check first document is open or not ? so pls tell me how check pdf control have document or not before going to close.

Note: Need to check in if condition like

If(PDFxDoc) Then 'Here need to check pdf control have document or not ? how to check here ??

PDFxDoc.CloseDocument(0)'This line close document

Else

EndIF



Pls reply asap

Regards
Aravind


It seem like a question to the company wrote the ActiveX...
http://www.tracker-software.com/product/pdf-xchange-viewer-activex-sdk[^]


这篇关于如何查看pdf viewer是否打开了pdf文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆