Babylon 5 was like reading a good book whereas Star Trek is like watching a scene from a given 007 movie. Sure some of those scenes are really slick but when added together they don't add up to a whole lot (ie Moonraker, License to Kill, The Man w/Golden Gun). Babylon 5 however had meaningful connections between its episodes.
If both had great actors/characters it would be a hard choice to pic given similar time slots. But considering how Star Trek, with the exception of The Next Generation, has been throwing out crappy actors and stories it would not be hard for me to choose Babylon.
Lastly, Babylon 5, although very good when watched as a chronicle is almost impossible to pick up part way through unless you have already watched the series once. Who the hell are these aliens? What the hell is that guy planning/double/triple crossing? In Star Trek the people are always the same and the end of each episode (except for the 2x episodes) end with Kirk/Picard/DS9Captian/Janeway sitting on the helm with the ship peacefully floating through untroubled space.
My vote goes to Babylon 5 followed closely by The Next Generation and then by Gideon's Crossing
