Quantcast
Channel: Active questions tagged excel - Stack Overflow
Viewing all articles
Browse latest Browse all 90280

Set the currency symbol when writing with xlsxwriter

$
0
0

I'm having trouble writing the currency symbol I want in my currency values with xlsxwriter.

I followed the tutorial here and I'm able to write out currency values with the correct formatting and a dollar sign (whether this is from the tutorial or excel's default settings I'm not sure).

This works:

money = workbook.add_format({'num_format':'$#,##0.00'})

And it prints out a currency value with the dollar sign.

$1,000.00

But if I try to insert my own currency, let's say R:

money = workbook.add_format({'num_format':'R#,##0.00'})

I get this:

R1000

How can I set the currency symbol using xlsxwriter?


Viewing all articles
Browse latest Browse all 90280

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>