This is a migrated thread and some comments may be shown as answers.

[Solved] Currency CellContentFormat

3 Answers 280 Views
Grid for XAML
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
jasonxz
Top achievements
Rank 1
jasonxz asked on 01 Jun 2013, 03:11 AM
This is the only documentation I can find about the CellContentFormat property and it's not exactly helpful for my goal:

http://www.telerik.com/help/windows-8-xaml/datagrid-columns-textcolumn.html

Anyways, all I want to do is use the CellContentFormat property of the DataGridTextColumn to render a decimal value into a "Currency" format.  I can't imagine this is difficult, but I can't figure it out (probably just need to go to bed).

I'd prefer to be using the DataGridNumericalColumn (http://www.telerik.com/help/windows-8-xaml/datagrid-columns-numericalcolumn.html)but it doesn't seem to be a part of the version of the tools I have.

3 Answers, 1 is accepted

Sort by
0
jasonxz
Top achievements
Rank 1
answered on 02 Jun 2013, 03:30 AM
Never mind.
I found it in the Grid example that came with the tools:

CellContentFormat="{}{0,0:C0}"

0
jasonxz
Top achievements
Rank 1
answered on 02 Jun 2013, 03:38 AM
Oh, and if you want it to show cents as well as dollars, it looks like this:
CellContentFormat="{}{0,0:C2}"
0
Ivaylo Gergov
Telerik team
answered on 04 Jun 2013, 12:04 PM
Hello Jason,

Thank you for using our RadControls for Windows 8.

I see that you have found how to format text to a currency. Also, the mentioned DataGridNumericalColumn is part of our latest Q2 2013 Beta release that you can download from your Account -> Products & Subscriptions -> DevCraft Ultimate -> Download Installer and other Resources -> RadControls for Windows 8 -> Browse all product files -> Beta. Note, that our official Q2 2013 release will be available next week.

If you have any other questions do not hesitate to contact us again.

 

Regards,
Ivaylo Gergov
Telerik
Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
Tags
Grid for XAML
Asked by
jasonxz
Top achievements
Rank 1
Answers by
jasonxz
Top achievements
Rank 1
Ivaylo Gergov
Telerik team
Share this question
or