"mso-" style?

  • Thread starter Thread starter cdars
  • Start date Start date
C

cdars

Hi,

I came across "mso-" style for the first time yesterday after 6 years
of web development. That's the first time I know about this and
"mso-spacerun" saves my day by displaying " " as ASCII(20) instead
of ASCII(160).

<span>A&nbsp;B</span>
<span style="mso-spacerun:yes;">A&nbsp;B</span>

I wonder there should be more "mso-" style. But I can't find it at
MSDN, Google search, not to mention CSS books.

Is there any documentation on this?

Thanks.
John
 
Hi cdars,

You obviously have never used Word or Excel to publish a web page!

Search MSDN for 'Office Styles'

Regards.
 
No I didn't. All my learning was about standard CSS attributes.

The search on MSDN returns something about VBA. I am more interested on
the HTML source generated by saving a document in HTML using Word /
Excel. This is because we have an application (in ASP 3.0) trying to
generate Excel files in HTML source.
We find that that if we used &nbsp; in a cell content, it is
interrupted as ASCII 160 in an Excel cell. If a real space was used, it
will be usual ASCII 20. However we have to stick with &nbsp; since the
text string would contain double space. Should the HTML source have 2
space characters stick together, it is shown as 1 space in the cell
content, a native HTML behavior.

Using the "mso-spacerun" style, you can use A&nbsp;B in the HTML source
generation. Excel shows a space in a cell and the middle character
would be ASCII 20.

You know any source explaining other "mso-" CSS attributes?
 
Back
Top