View Single Post
  #5   Report Post  
tifosi3
 
Posts: n/a
Default

I tried this, did not seem to work, also I am looking for it to format to a
specific cell. Also I am not even basically proficient in VB, so I am having
trouble following the logic. Though I appreciate your help.

"Don Guillett" wrote:

PRE format column 3 click on sheet tabview codeinsert this.
Now when you type in a 16 digit number in col C below row 1 you will get it

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Row < 2 Or Target.Column < 3 Then Exit Sub
Target.Value = Format(Target, "0000 0000 0000 0000")
End Sub

--
Don Guillett
SalesAid Software

"tifosi3" wrote in message
...
I am trying to format a cell to a credit card format, so the user can

enter
only the numbers and have the dashes between each set of four digits auto
populate. I have tried using both 0000-0000-0000-0000 and
####-####-####-####, and each of these puts a zero at the end. Any
suggestions? THanks in advance for your help.