Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
How do i preserve css styling when opening an html file in word?
I have an html file which has some basic styling - style="float:right". When
I open this file up in word, word ignores the styles. How do i get word to use the style. What I am trying to achieve is to create an html page where some text appears on the right of the page and this is preserved when opening the page in word. The html page has to drive this behaviour as I can't modify any word settings. |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
How do i preserve css styling when opening an html file in word?
Hi D.J.,
This article lists some of the limitations of page layout via HTML in Word http://support.microsoft.com/kb/212270 You won't be able to 'float' text for positioning without it being supported in a frame or shape or table, Word isn't page layout software, but Word can justify text right in a paragraph or wrap it around a picture. 'Float', if you're referring to a top level CSS class is one of the CSS elements that Word doesn't support. Word is supposed to ignore the elements it does not support. Without having a link to the web page to view, not knowing the version of Word you're using, or if you're using embedded CSS, or an attached CSS sheet, what you may want to try is creating a page in Word the way you want it to look while you're in Web Layout view, and then use File=Web Page Preview (if pre Word 2007) to open the page in the browser and then in your browser right click and use View=Source to see how word positioned the graphic, then mimic that CSS in the creation of the HTML page. =============== "dj" wrote in message ... I have an html file which has some basic styling - style="float:right". When I open this file up in word, word ignores the styles. How do i get word to use the style. What I am trying to achieve is to create an html page where some text appears on the right of the page and this is preserved when opening the page in word. The html page has to drive this behaviour as I can't modify any word settings. -- Bob Buckland ?:-) MS Office System Products MVP *Courtesy is not expensive and can pay big dividends* |
#3
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
How do i preserve css styling when opening an html file in wor
Hi Bob,
Thanks for your reply. I am going to try this out on Monday when I'm back at work. "Bob Buckland ?:-)" wrote: Hi D.J., This article lists some of the limitations of page layout via HTML in Word http://support.microsoft.com/kb/212270 You won't be able to 'float' text for positioning without it being supported in a frame or shape or table, Word isn't page layout software, but Word can justify text right in a paragraph or wrap it around a picture. 'Float', if you're referring to a top level CSS class is one of the CSS elements that Word doesn't support. Word is supposed to ignore the elements it does not support. Without having a link to the web page to view, not knowing the version of Word you're using, or if you're using embedded CSS, or an attached CSS sheet, what you may want to try is creating a page in Word the way you want it to look while you're in Web Layout view, and then use File=Web Page Preview (if pre Word 2007) to open the page in the browser and then in your browser right click and use View=Source to see how word positioned the graphic, then mimic that CSS in the creation of the HTML page. =============== "dj" wrote in message ... I have an html file which has some basic styling - style="float:right". When I open this file up in word, word ignores the styles. How do i get word to use the style. What I am trying to achieve is to create an html page where some text appears on the right of the page and this is preserved when opening the page in word. The html page has to drive this behaviour as I can't modify any word settings. -- Bob Buckland ?:-) MS Office System Products MVP *Courtesy is not expensive and can pay big dividends* |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Issues while opening HTML document for editing in WORD | Microsoft Word Help | |||
Extra carriage returns when opening an HTML file in Word. | Microsoft Word Help | |||
How can I convert a WORD document to html and preserve columns | Microsoft Word Help | |||
Opening HTML doc in Word: Can control the template? | Microsoft Word Help | |||
prevent txt file from opening as html? | Microsoft Word Help |