在vckbase上找到下面的文章
做个PDF格式电子图书浏览器——浅谈一类控件的使用
http://www.vckbase.com/document/viewdoc/?id=1049这是针对低版本的.用Visual C++实现PDF文件的显示
http://soft.zdnet.com.cn/software_zone/2007/1016/558788.shtml和 Adobe ActiveX Control with MFC
http://www.codeproject.com/KB/miscctrl/acroview.aspx
这是针对高版本的.我的问题是,我如何判断 用户安装的Adobe pdf 阅读器 是高版本的还是低版本的.
如果用户电脑没有安装 Adobe pdf 阅读器,我能否将pdf.ocx和其相关的程序(DLL或者OCX),在用户安装我的软件时,安装到用户的系统上.如果这个思路可以,我都需要拷贝 Adobe pdf 阅读器的那些文件? 

解决方案 »

  1.   

    1. 通过注册表可以判断。
    2. 带一份Adobe Reader(这个是免费的,可以自由分发),做在安装程序里,
    让用户选择安装。
      

  2.   


    如何 带一份Adobe Reader?请具体说说
      

  3.   


    会用installshield等安装程序制作工具的话,都可以做到的。
      

  4.   

    找到一份InstallShield中判断Acrobat的installscript,按它的思路修改一下吧。// AcrobatGetOpenCmd returns the string you need to use to run Acrobat - you 
    // pass this string to LaunchApp.
    //
    // _IsPresentAcrobat returns TRUE if Acrobat is loaded, else FALSE.// Updated 04/12/1999 because Acrobat Reader 4.0 stores something like
    // "C:\Program Files\Adobe\Acrobat 4.0\Reader;C:\Program Files\Adobe\Acrobat 4.0\Resource\Lib"
    // in the Path registry key
    prototype   _AcrobatGetOpenCmd ( BYREF STRING );
    prototype   _IsPresentAcrobat ();
    #define constAcrobatAppPthKey "\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\App Paths\\AcroRd32.exe"
    #define constAcrobatVerKey    "\\SOFTWARE\\Adobe"
    //----------------------------------------------------------------
    // Get Acrobat exec cmd (default) val under registry key
    //      HKEY_CLASSES_ROOT\AcroExch.Document\shell\open\commandfunction _AcrobatGetOpenCmd ( szPgmAcrobat )
    LONG    nvType, nvSize;
    begin
        RegDBSetDefaultRoot( HKEY_LOCAL_MACHINE );    if ( RegDBGetKeyValueEx ( constAcrobatAppPthKey,
                "",    // Retrieve "(Default)" value name, e.g., C:\Acrobat3\Reader
                nvType, szPgmAcrobat, nvSize) != 0 ) then
            szPgmAcrobat = "";
        endif;
    end;    // function _AcrobatGetOpenCmdfunction _IsPresentAcrobat ()STRING  svPathPlusEXEName, svEXEName, svPath, svResult;
    LONG    nvType, nvSize;begin
        RegDBSetDefaultRoot( HKEY_LOCAL_MACHINE );
        if ( RegDBKeyExist ( constAcrobatAppPthKey ) != 1 ) then
            return FALSE;
        endif;    if ( RegDBGetKeyValueEx ( constAcrobatAppPthKey,
                "Path",    // Retrieve "Path" value name, e.g., C:\Acrobat3\Reader
                nvType, svPath, nvSize) != 0 ) then
            return FALSE;
        endif;    if ( RegDBGetKeyValueEx ( constAcrobatAppPthKey,
                "",             // Retrieve "(default)" value name
                nvType, svPathPlusEXEName, nvSize) != 0 ) then
            return FALSE;
        endif;    if ( ParsePath (svEXEName, svPathPlusEXEName, FILENAME) != 0 ) then
            return FALSE;
        endif;    // added 04/12/1999 for Acrobat 4.0 compatibility
        if ( ParsePath (svPath, svPathPlusEXEName, PATH) != 0 ) then
            return FALSE;
        endif;    if ( FindFile (svPath, svEXEName, svResult) != 0 ) then
            return FALSE;
        endif;    return TRUE;
    end;    // function _IsPresentAcrobat
      

  5.   


    1.从注册表找,可以用COM库名称,PDF.PdfCtrl.5(版本号)或者组件的GUID,
    2.好像有专门的抓包工具,看看那些组件被引用了,然后一起拷贝制作安装包,找一台没装adobe reader的机器安装试试咯;是在不行的话,带个adobe reader的安装包吧,好像是免费的。
      

  6.   

    使用 一个 pdf阅读控件就可以. 如果对xpdf熟悉,可以修改原代码,做一个PDF阅读控件.