Garmin 430 and family: "Direct To" the waypoint (VOR), then press the OBS button. Using the physical round dial (if fitted & connected) or the pop-up menu of the 430 (if not), to set the OBS value. The magenta line now shows the to/from bearings. Extrapolate the "scale" line/bar (lower left corner of the GPS map display) mentally on that bearing line and you know where you are vs. that other aircraft.
Having said that, I would not do this at all. If the aircraft is far away there's no conflict and by the time you are at his position he'll be gone anyway. And if there is a potential conflict, a simple bearing like this is way too inaccurate to take proper avoiding action. It's much better to be looking outside than to have your eyes in the cockpit trying to program the box.