Detect whether MS Office installed is 32bit or 64bit by using registry

前端 未结 4 1771
Happy的楠姐
Happy的楠姐 2021-01-14 06:01

I want to install vsto addin based on the excel version (32 bit or 64 bit). I am planning to bundle both 32bit and 64 bit msis and install one by determining the excel versi

4条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-01-14 06:23

    First, look for the installed version of Outlook in this key:

    HKEY_CLASSES_ROOT\Outlook.Application\CurVer

    The value will be Outlook.Application.15 (for 2013). Then parse that value to get the integer and lookup this key:

    HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Office\15.0\Outlook

    If it exists, check the value of Bitness to determine if it is 32-bit (x86) or 64-bit (x64). If it doesn't exist, assume 32-bit.

提交回复
热议问题