Group:  Microsoft Excel ยป microsoft.public.excel.misc
Thread: Splitting Numbers Into Different Columns

DotNetBag
.NET Development Newsgroups

HTVi
TV Discussion Newsgroups

Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
Rising Antivirus 2006

Splitting Numbers Into Different Columns
"Peter W Soady \(UK\)" <devils_joy[ at ]hotmail.con> 30.09.2006 17:44:09
Hi

I have a small problem which I can partly solve but not fully. The scenario
is following:

I have columns formated as number with 2 decimal places however I need to
split these columns into whole number and decimal number but I need the
whole number to be 4 digits in length. Example

New Columns
Original Col Whole Num Decimal Num
0.12 0000 12
12.12 0012 12
120.12 0120 12

I am not interested in the decimal point but the columns must conform to the
above or the Oracle Application will reject the import

I have tried different ways using the IF and LEN but seem to be banging
against the brick wall. I would accept any way of doing this, Macro, VBA or
Function. Howecver if it is macro or VBA I will also require the knowledge
on how to attach this to the worksheet

Any help would be greatly appreciated


Peter W S


Re: Splitting Numbers Into Different Columns
"Don Guillett" <dguillett1[ at ]austin.rr.com> 30.09.2006 18:03:15
try selecting cells>right click>format>custom 0000

--
Don Guillett
SalesAid Software
dguillett1[ at ]austin.rr.com
"Peter W Soady (UK)" <devils_joy[ at ]hotmail.con> wrote in message
news:e2aFGgL5GHA.3452[ at ]TK2MSFTNGP05.phx.gbl...
[Quoted Text]
> Hi
>
> I have a small problem which I can partly solve but not fully. The
> scenario is following:
>
> I have columns formated as number with 2 decimal places however I need to
> split these columns into whole number and decimal number but I need the
> whole number to be 4 digits in length. Example
>
> New Columns
> Original Col Whole Num Decimal Num
> 0.12 0000 12
> 12.12 0012 12
> 120.12 0120 12
>
> I am not interested in the decimal point but the columns must conform to
> the above or the Oracle Application will reject the import
>
> I have tried different ways using the IF and LEN but seem to be banging
> against the brick wall. I would accept any way of doing this, Macro, VBA
> or Function. Howecver if it is macro or VBA I will also require the
> knowledge on how to attach this to the worksheet
>
> Any help would be greatly appreciated
>
>
> Peter W S
>
>


Re: Splitting Numbers Into Different Columns
"Carim" <carimfam[ at ]yahoo.com> 30.09.2006 18:08:44
Hi Peter

Assuming numbers are column A :
in column B just type formula =Int(A1) and then Format Cells Number
Custom 0000
and copy this formula all the way down
in column C just type formula = B1-A1 and Format Cells Number Number 2
decimals

HTH
Cheers
Carim

RE: Splitting Numbers Into Different Columns
JMB 30.09.2006 18:57:01
I've never tried to import anything into an Oracle application, so I'm not
sure whether or not your application will accept numbers that are only
formatted to display 4 digits. If the other suggestions don't work, maybe

=TEXT(INT(A1), "0000")



"Peter W Soady (UK)" wrote:

[Quoted Text]
> Hi
>
> I have a small problem which I can partly solve but not fully. The scenario
> is following:
>
> I have columns formated as number with 2 decimal places however I need to
> split these columns into whole number and decimal number but I need the
> whole number to be 4 digits in length. Example
>
> New Columns
> Original Col Whole Num Decimal Num
> 0.12 0000 12
> 12.12 0012 12
> 120.12 0120 12
>
> I am not interested in the decimal point but the columns must conform to the
> above or the Oracle Application will reject the import
>
> I have tried different ways using the IF and LEN but seem to be banging
> against the brick wall. I would accept any way of doing this, Macro, VBA or
> Function. Howecver if it is macro or VBA I will also require the knowledge
> on how to attach this to the worksheet
>
> Any help would be greatly appreciated
>
>
> Peter W S
>
>
>

Home | Search | Terms | Imprint | Contact
Newsgroups Reader - provided by WiredBox.Net