Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 05-27-2011, 10:17 PM   #1
GeekyGal
Enthusiast
GeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavens
 
Posts: 38
Karma: 13888
Join Date: Sep 2010
Device: Kindle FireHD, Kindle3G, iPad, MacBook, iRex Illiad (ret)
Formatting Floating Point # Custom Column

Dear Very Helpful Calibre Community,

I may just be missing something really basic, but how do I format a column to force two digits after the decimal point? I have a floating point number column which truncates trailing zeros I would like to show.

Thank you very much.
GeekyGal is offline   Reply With Quote
Old 05-30-2011, 04:01 PM   #2
chaley
Wizard
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 3,853
Karma: 285886
Join Date: Jan 2010
Location: France
Device: Sony PRS-300, HTC WM6.5, Samsung Galaxy Nexus, HTC Sensation
The latest release (0.8.3) provides a general mechanism for formatting numeric custom columns. There is a new box in the column definition for entering a format specifier to format the number. The tooltips in the column definition box provide a few examples.

Note that although the format specifier looks like a template, it is not. The template language also uses format specifiers, which is why they have a similar look.

The format to do what you asked would be {0:.2f}
__________________
Support calibre developers at no cost to you by using calibre's get books feature.
Use Calibre Companion to wirelessly connect your Android phone or tablet to calibre
charles.haleys.org/calibre
chaley is offline   Reply With Quote
 
Enthusiast
Old 06-03-2011, 05:25 PM   #3
GeekyGal
Enthusiast
GeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavens
 
Posts: 38
Karma: 13888
Join Date: Sep 2010
Device: Kindle FireHD, Kindle3G, iPad, MacBook, iRex Illiad (ret)
THANK YOU, chaley. The new version [8.4 today] has a VERY easy fix for my exact issue. Your reply helped me so much.

GeekyGal
GeekyGal is offline   Reply With Quote
Old 06-03-2011, 05:34 PM   #4
chaley
Wizard
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 3,853
Karma: 285886
Join Date: Jan 2010
Location: France
Device: Sony PRS-300, HTC WM6.5, Samsung Galaxy Nexus, HTC Sensation
You are welcome.
__________________
Support calibre developers at no cost to you by using calibre's get books feature.
Use Calibre Companion to wirelessly connect your Android phone or tablet to calibre
charles.haleys.org/calibre
chaley is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with Search - Floating Point Number nynaevelan Library Management 16 04-13-2011 06:37 AM
Can custom book data be displayed in a custom column? kiwidude Development 9 03-02-2011 05:35 AM
Need help with this custom Column. Rie142 Library Management 2 02-20-2011 09:51 AM
custom column i need a little help shinken Calibre 3 09-15-2010 03:41 AM
custom column not searchable SkyDream Calibre 5 07-26-2010 05:38 AM


All times are GMT -4. The time now is 12:13 PM.


MobileRead.com is a privately owned, operated and funded community.