Hello,
I think that there are two cases that we should take into consideration here:
1- If the Windows OS is a 32-bit OS ==> the Office must be of 32-bit as well. The condition for this can look like this:
"VersionNT64" is the property indicating that the Windows OS architecture is of 64-bit. Negating it will mean that the OS architecture is of 32-bit.
2- Now if the OS architecture is of 64-bit, there can be two more cases:
- If Office is of 64-bits, it will write information under the following hive key:
HKEY_LOCAL_MACHINE\SOFTWARE\...\...\....
- If Office is of 32-bits, it will write information under the following hive key:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\...\...\...
I think that in the second case, you could proceed as it follows in order to see if Office is of 32-bit or 64-bit:
- Create two registry searches for the two versions of Office and based on the result of the search, decide which .mdb file to be copied.
In what regards to the result of the search, for instance, if you are going to use a
"registry key exists" search, there can be two cases:
- the property that stores the search result is 1 if it was successful.
- the property that stores the search result is empty if it does not find the registry key.
Based on what was said above, the condition can look like this:
Move the .mdb file if:
Also, as an important note: This may get a little bit troublesome, since I think that every version of Office will write to different registry entries. With that being said, you may need to create 2 searches for every version of Office out there.
Hope this helps.
All the best,
Catalin