View Single Post
  #11   Report Post  
Posted to microsoft.public.excel.programming
Ron Rosenfeld[_2_] Ron Rosenfeld[_2_] is offline
external usenet poster
 
Posts: 1,045
Default Format Telephone Numbers

On Fri, 12 Nov 2010 16:35:59 -0600, "JCO"
wrote:

Sorry it took so long... I've been vacationing in Mexico for the past week.
I read your reply. So what do I have to do to have it appear in Text
format? I actually think the text field is preferred in my case.


Just output it as a formatted text string.

So instead of:

==========================
.Value = re.Replace(.Text, "")
.NumberFormat = _
"[9999999]000\.000\.0000;000\.0000"
============================

You'd have something like (not tested):

==============================
..Value = Format(re.replace(.text,""), _
"[9999999]000\.000\.0000;000\.0000"
===============================