Well, as with all things, it depends.

However, I can offer a few pieces of advice.
Currency is nice in that it works without you having to do anything - all those new trade routes will automatically start generating more gold for you as soon as you research the technology. Currency is a particularly nice option if you have many different foreign cities reachable by trade this early in the game. It's not so great for small island starts with just two or three players, but is still helpful even in this kind of situation.
For Code of Laws to be effective, you will not only have to research the technology but also to invest many hammers into building the Courthouses. At this early stage in the game, it is not likely that you will save more than 2-3 gold per turn per Courthouse per city. This is only slightly more than the trade routes from Currency might yield you, and for a lot more effort. Courthouses might be very difficult to build in some of the smaller and recently captured cities of your empire, since their production may not be up to scratch. The cities that can best produce Courthouses will most likely be near the core of your empire anyway (and therefore have less maintenance to be saved). An additional factor is that while you are building Courthouses, you cannot simultaneously be building a unit in those cities, which potentially slows down or brings to a halt your military campaigns.
Overall, in a general situation (though no such thing really exists), I would probably personally have a preference for Currency over Code of Laws for bettering my empire's economy. However, other circumstances could of course tilt the decision (for just one example, Organised leaders get double production speed on their Courthouses, which is a heavy incentive for getting them).
I suspect that other people might have different (and equally valid) opinions on this matter, and I'm sure they'll point them out to you. Of course, perhaps the best answer is to just get both of the technologies that you mentioned, to maximise your economy's potential.
No, it is not possible to do this without denying yourself resources. However, at certain stages in the game it is possible to research technologies in a strategic order so that you can keep your options open. For instance, by making a beeline towards Chemistry but waiting a long time to get Rifling, you will be able to build both Grenadiers and Macemen for a considerable period of time (which is great, since you can choose to build Macemen, give them city raider promotions and then upgrade them to Grenadiers for a small amount of gold).