Update 2017:
You can do even better than this using scripting, which adds more intelligence to the way Beyond Compare is launched from Opus, and lets you have a single button that works in different contexts (e.g. comparing the source/dest folders if nothing is selected, or files if something is selected, etc.)
See this thread for the script method:
(Updated December 2011)
I use a slightly different command so I thought I'd share it here:
-
Replacement for 1 & 3 combined: Compare two files, or two folders, between left and right file displays:
"C:\Program Files (x86)\Beyond Compare 3\BComp.exe" {leftpath}{file} {rightpath}{file} @nodeselect
(32-bit users: Change Program Files (x86) to Program Files in the command.)
If no files are selected then clicking the button will tell Beyond Compare to compare the left and right folders.
If you select one or more files in either side of a dual-display window, then click the button, they will be compared against the files with the same names in the other side.
With multiple files selected, this works best if you configure Beyond Compare to use multiple tabs instead of multiple windows.
The button also ensures that Beyond Compare's left and right sides match what's displayed in Opus. (e.g. If the right-hand side happens to be active in Opus, it'll still be on the right in Beyond Compare, not swapped to the left.)
That works great for comparing folders, and for comparing files when they have the same names in both folders, and when you are using a dual-display window.
-
Alternative that works with different filenames and separate windows:
It's also possible to make a similar button that works across two single-display windows, and also works for comparing files which have different names in each side.
In this case, you have to select the file you want to compare in each side or window, so the button knows what you want.
The button is also more complex to create, since it requires a User Command.
Details of it are in a separate thread, File equivalent of {rightpath}/{leftpath}. (You want the first reply, from 2008. My reply from 2011 discusses the method I just gave above.)