A very basic Geeklet to display the current exchange rate as displayed in the Bloomberg web site. Useful in these uncertain times...

Just insert code below in the Command box, set the refresh to 300, resize the window and let it go.

On the same basis, one can create a similar command to extract a specific NAV on a given fund registered with Bloomberg.

Code is as follows:

curl -s http://www.bloomberg.com/quote/EURUSD:CUR/ | sed -n "/<h3 class=\"\">EUR-USD<\/h3>/,/<span class=\"currency_factor_description\">/p" | sed -e "s/<[^>]*>//g; s/ *//g; /^*$/d" | strings

Geeklet files to download


User Avatar
wjx 2570 days ago
Thanks for this! I'm trying to modify it to spit out other quotes from bloomberg, but the bits I generally change don't seem to work. I am a complete geeklet noob just starting to learn code. Codes i use for sites like google fi and yahoo fi usually only need the ticker modified, and whatever language is used to describe the displayed quote. This isn't working for me here, so I conclude bloombergs code must work differently. This is what I have so far, but I know there is more that needs to be modified, just not sure what:

curl -s http://www.bloomberg.com/quote/GSPGY:IND/ | sed -n "/Spanish 2 year/,//p" | sed -e "s/]*>//g; s/ *//g; /^*$/d" | strings

Thanks in advance for any help.
User Avatar
wjx 2570 days ago
Funny, but not all the code I enter into this comment box makes it onto the page, despite my trying to edit the comment.
User Avatar
yogikagoge 2546 days ago
I tried substituting BRL for EUR and it doesn't seem to work. Any advice?
User Avatar
flp404 2531 days ago
Great tool, it works with other quotes, but the description must follow the same order of code CUR:

I did it for MXN - USD following next:

curl -s http://www.bloomberg.com/quote/USDMXN:CUR/ | sed -n "/USD-MXN/,//p" | sed -e "s/]*>//g; s/ *//g; /^*$/d" | strings


Log in to comment or register here.