Barcelona is unfortunately well known for its pickpocketing problem, therefore instead of carrying large amount of cash, I would recommend using ATMs (automated teller machine) as it is the easiest way to get cash. However, before you start your travel, you should contact your bank in order to find out what charges they will apply. Rembember that in order to use your credit card abroad, you will need a valid PIN number. Also, if you have several credit cards, use the one that offers you the best deal (the one that applies the smallest charge).
However, if you have to exchange money (e.g. US Dollars or British pounds to Euros), I would strongly recommend that you use a regular bank (La Caixa, Catalunya Caixa, Caixa Penedes, BBVA …) rather than exchange kiosks as the exchange ratio is more favorable in a regular bank. Moreover, financial institutions post their exchange rates outside so you will be able to compare their ratio to the ratios applied by the exchange kioks. Use only exchange kiosks as a last resort as they will rip you off.
When changing your money, ensure that you get loose change as it will be very useful if for example you have to use public transportation. As a safety measure, keep always the change in a different location than large notes.