Archive for the ‘Library or Class’ Category

ClsWheel 1.7

September 25, 2013

Class, B4A: ClsWheel, Type 5 = DIGITS

Published September 2013

I’ve been using B4A for several projects, including MIR-Blue. After finding out that Modal Dialogs cause a message ordering problem for AsyncText, I needed some reusable non-modal controls to replace the (modal) Dialogs library I first used. Klaus has written ClsWheel which I found very useful (Thanks Klaus!); but I found that while it handled Dates, multiple ‘wheel position’ elements and such, there was some boilerplate code required to use the CUSTOM mode for a simple multiple digit decimal number.

So I coded up a solution for it, providing an optional decimal point position specification. Mode 5 DIGITS accepts a 1-5 digit decimal number (with decimal point), and returns the same. The return can be assigned to an Int, Float or Double if desired, without extra processing. By default, ClsWheel uses a Space ” ” separator between wheel ‘digits’.

Of course I make this freely available, how could I not after Klaus’s contribution.

Update: Klaus accepted it, and is giving it his own spin, adding support for +-, movable decimal point, and other useful features.

Since there are some costs to me for these efforts, if you find value in any of my work, please consider a donation.

Please consider a donation if you find value in my free/open source contributions.