-----------------------------------------------------------
New Message on BDOTNET
-----------------------------------------------------------
From: Raj_MS
Message 5 in Discussion
The following works in Excel 2003. Should work in earlier versions also. In your
ASP.NET page, emit an HTML Style tag, where you define a style called, say,
myformattednumber. This should look like this when emitted: <STYLE> <!--
.myformattednumber { mso-number-format:0000000000000; } --> </STYLE> Next, you need
to make the datagrid column which emits your number use this CSS class. If this is the
only numeric column you have, the easiest way to do this is to set the CSSClass
property of the ItemStyle property of your DataGrid to myformattednumber, as in:
DataGrid1.ItemStyle.CssClass="myformattednumber" Do this before databinding. Now,
excel will format your column properly. Of course, do not put any quotes or
apostrophes. Emit a number. Regards Raj
-----------------------------------------------------------
To stop getting this e-mail, or change how often it arrives, go to your E-mail
Settings.
http://groups.msn.com/BDotNet/_emailsettings.msnw
Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help
For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact
If you do not want to receive future e-mail from this MSN group, or if you received
this message by mistake, please click the "Remove" link below. On the pre-addressed
e-mail message that opens, simply click "Send". Your e-mail address will be deleted
from this group's mailing list.
mailto:[EMAIL PROTECTED]