Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 12
Default make 1234 - 012034

I have a cell with a 4 digit number that i need to convert to 6 digit with
zeros. Is there a way i can do this in a macro?

I have 1234
I need 012034

thanks.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 46
Default make 1234 - 012034

How about
="0"&LEFT(A1,2)&"0"&RIGHT(A1,2)

In macro, substitute A1 with range

"Daniel M" wrote:

I have a cell with a 4 digit number that i need to convert to 6 digit with
zeros. Is there a way i can do this in a macro?

I have 1234
I need 012034

thanks.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Copied number eg 1234- to display as (1234.00) in red in Excel dallas Excel Worksheet Functions 2 March 7th 07 11:25 PM
Changing 123456 to $1234.56 YoYo2 Excel Worksheet Functions 4 January 25th 07 12:03 PM
how do I add all numbers in the same cell... 1234 = 10 DR_LR_N_SC Excel Discussion (Misc queries) 2 October 23rd 06 02:03 AM
Changing 1234.00- to -1234.00 automatically Lisa Excel Discussion (Misc queries) 7 September 28th 06 09:20 PM
how to change (555)123-1234 to 5551231234 JMB Excel Discussion (Misc queries) 0 February 3rd 06 11:43 AM


All times are GMT +1. The time now is 08:22 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"