Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default leading zeros!!!! arrrrrrgh! please help

hello,

i've been searching for (literally) 3hours on the web... apparently i'm the
only one ever to have encountered this...

i want to put a value of "0204" in a cell via vb. short story.... can't.
it's "204". always.

i need a way to have excel format the cell as text.... please for the love
of humanity.... anyone know how to do this? i'ts vb6 and excel 2k3

any help would be GREATLY appreciated

dushan


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 25
Default leading zeros!!!! arrrrrrgh! please help

Hi Dushan,

Try to use a custom format in XL2003... along these lines:
0########
or in VBA use:
Range("Whatever").NumberFormat = "0########"

Should work orright...

Cheers,
spIky haIred

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
Add Leading Zeros Erika Excel Discussion (Misc queries) 4 March 27th 09 04:55 PM
Leading zeros mary Excel Discussion (Misc queries) 1 January 18th 06 01:56 PM
Leading zeros LeePotts Excel Discussion (Misc queries) 2 August 17th 05 02:46 PM
save text field w/ leading zeros in .csv format & not lose zeros? Ques Excel Discussion (Misc queries) 1 May 4th 05 06:21 PM
Leading zeros JC Excel Discussion (Misc queries) 9 February 1st 05 02:33 PM


All times are GMT +1. The time now is 05:21 AM.

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"