Thread: Adding zeros
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
abxy[_43_] abxy[_43_] is offline
external usenet poster
 
Posts: 1
Default Adding zeros

ok, i have a string of code in my userform that looks like this:

If Application.CountIf(ws.Cells.Range("A1:A275"), *"000"
TextBox1.Value*) 0 Then

now, the thing is, i've discovered that saying 000 and textbox1.valu
won't always give you the desired result, so, my question is, how can
alter that line of code to say, textbox1.value and keep adding zeros i
front of it, until there are 7 digits?

thanks for helping me out :

--
Message posted from http://www.ExcelForum.com