Sorry for taking so long to respond, work took over. I used both of
the suggestion you guys gave me and came up with the following
solution. Thanks very much for all your help!!
<asp:Label ID="PhoneLabel" runat="server"
Text='<%#
(String.IsNullOrEmpty(Convert.ToString(Eval("Phone"))))?"":String.Format("{0:
(###) ###-####}", Convert.ToInt64(Eval("Phone"))) %>' />
On Oct 12, 2:36 pm, Cerebrus <[email protected]> wrote:
> IMO, it has to do with the fact that the syntax is erroneous. The
> other possibility is the fact that the number is stored as VarChar
> which results in it being retrieved as a string in .NET. Strings do
> not get formatted using the "#" format specifier.
>
> On Oct 13, 12:26 am, Stephen Russell <[email protected]> wrote:
>
>
>
>
>
> > No it has to do with data collection and nothing to do with storage.
> > You can fix it on the extraction easily with ISNULL(phoneNumber,
> > 'YourStringHere' )
>
> > --
> > Stephen Russell
>
> > Sr. Production Systems Programmer
> > CIMSgts
>
> > 901.246-0159 cell