Actually I guess it would be more..consistent if you just did this:

double input = 123.456;
double leftSide = System.Math.Floor(input);
double rightSide = input - System.Math.Floor(input);

On Dec 5, 1:38 pm, rhaazy <[EMAIL PROTECTED]> wrote:
> Did not test but I am pretty sure it's something like this:
>
> double input = 123.456;
> double leftSide = System.Math.Truncate(input);
> double rightSide = input - System.Math.Floor(input);
>
> On Dec 5, 12:30 pm, Zac <[EMAIL PROTECTED]> wrote:
>
>
>
> > Quick question. Say I have a decimal 160.37863763 . Is there an easy
> > way to break it up into a whole number and a decimal?
> > i.e. 160 in number A and .37863763 in number B?
>
> >  It's simple to do it by converting to a string and chopping it up,
> > but is there a way to do it while keeping it in a number type?
>
> > Thank!- Hide quoted text -
>
> - Show quoted text -

Reply via email to