Convert from Microsoft Word to Media Wiki Markup Style - ms-word

How do I export a word document to media wiki markup style
I have been trying to do it by following the steps given in http://en.wikipedia.org/wiki/Help:WordToWiki
but all in vain, not getting it.
Any help please.

Best way is to use Open Office
Open the Word document in Open Office Writer.
Go to File / Export.
Under File format choose MediaWiki (.txt).
Click Save (or Export).
Open the new file in a text editor and copy the contents to the clipboard.
Paste the text to a Wikipedia article.
That is copy and pasted from the document you linked to.
For Open Office 4.15 you have to add the extension Sun Wiki Publisher 1.1 with the extension manager.
If you don't want to install OpenOffice, another option is the Word2MediaWikiPlus extension.

In Microsoft Word 2016 I use the plugin "Microsoft Office Word Add-in For MediaWiki" (already suggested by Jake). https://www.microsoft.com/en-us/download/details.aspx?id=12298
To make it work in Microsoft Word 2016 (version 16.0). I followed these instructions but replaced "15.0" in the instruction to "16.0",
https://answers.microsoft.com/en-us/msoffice/forum/msoffice_word-mso_other/using-microsoft-office-word-add-in-for-mediawiki/449726c2-6d08-45e1-919a-4b5082ab4b5b

Microsoft has released an add-in for Microsoft Word that lets you export a doc file to MediaWiki formatting (as a .txt file). It's fairly decent.
http://www.microsoft.com/en-us/download/details.aspx?id=12298

If you're going to be doing this a lot, consider installing the FCK Editor. This has a Paste From Word button.

The easiest way may be to install LibreOffice (http://libreoffice.org) and open the Word document in its Writer application, then from there do Export and save to Media Wiki txt file. The Copy-paste that text into the Media Wiki at edit mode

but there was no way for adding images automatically that won't work for libreoffice or the word plugin.
If you have only a few docs for converting to the mediawiki, it is ok.
But if there ar more the it is great deal of time and effort.
For autom. Imageupload the only working solution was the discontinued project Word2MediaWikiPlus.
If somethings has changed in the last years let it me now.
But if not there are some solutions with work without image upload
(if I found them i will add these entry here):
- on webserer projekt which generated very good wiki markup output there , i can' t remember the name.
- a commandline tool that do the conversion as input and output file

Related

Update docvariable or docproperty in Word online

Is ther a way to update docvariable or docproperty of a Word document when opening in the Word online by the microsoft graph API or another API.
I do this in Word for desktop using C# code, but I need to do this in Word online too.
It can't be done in Word on-line. If you had an Office JS add-in you might be able to change document properties (but no DocProperty fields that reflect those values). The Word JS APIs do not access the Document Variables, however.
But you should be able to do it on the closed file (before it's opened in Word on-line, for example) by leveraging the Word Open XML file format. There are numerous libraries to work with it. Microsoft's is the Open XML SDK (free, as a .NET Framework / Visual Studio extension) which can access all content of Office files (except VBA binaries).

Convert HTML to a Word-document which can be edited in Word Online

Our users write in a rich-text field, pretty much like this one, and we would like for them to be able to export this as a Word Document in their OneDrive, preserving the formatting, and being able to open the file in Word Online.
I have no trouble creating new files using the https://graph.microsoft.com/v1.0/ api. The problem is the conversion to docx. The google api provides this conversion automatically, but I did not find that for Microsoft. I tried using html-docx-js and it almost works perfectly.
The file is created:
However when opening the file the following dialog pops up:
Opening in read-only mode works, the file shows with the correct formatting.
Downloading the file and opening in desktop word works perfectly (i.e. editing as well).
The HTML-content i use is a simple div with a few p-tags, so the "Objects that Word Online doesn't support" probably comes from html-docx-js.
Here's an example word-file that is created. This file can be opened as normal in desktop Word but only opened in read-only in Word Online
https://1drv.ms/w/s!AqpUGtnMiyurgwE543OscH7PdLnY
Any ideas?

Word 2013 to OpenXML Converter

Is there any converter available for Word 2013?
I had used one tool 2 years ago, which was converting Word 2010 Document to OpenXML Tags and C# code.
I am not able to recall its name. We just need to create a Word document with the format we need and then use that tool to convert it in OpenXML tags.
Anyone has any idea about this kind of tool ?
I have downloaded below tools, but they are not working for Word 2013.
Odf-AddInForWordSetup-en-1.0.exe
OdfAddInForOfficeSetup-en_4.0.5309.exe
Thank you,
I think you are looking for Open XML SDK 2.5 for Microsoft Office. In the link that I provided above its features are described:
Features include the ability to generate Open XML SDK 2.5 source code based on document content, compare source and target Open XML documents to reveal differences and to generate source code to create the target from the source, validate documents, and display documentation for the Open XML SDK 2.5 Classes, the ECMA376v1 standard, and the Microsoft Office implementation notes.

How can I open a .mediawiki file in Word so that Word will interpret it as a MediaWiki file rather than a TXT file?

I've recently installed the Microsoft Office Word Add-in For MediaWiki (http://www.microsoft.com/en-us/download/details.aspx?id=12298) and I'm able to save MediaWiki files just fine but I can't open them (they are opened as plain text).
How can I force MS Word to make the correct association for MediaWiki files?
You can't. "Interpreting" the MediaWiki markup, i.e. wikitext, is called parsing. Writing a MediaWiki parser is a pain and there is no single parser which fully works yet, other than MediaWiki itself. LibreOffice's wiki-publisher plugin and those which copied it are able to produce good wikitext from their well-formed data format, but making this bidirectional is another matter.
Parsoid is almost perfect now and produces standard HTML, but it's a rather heavy application, you can't expect it to be embedded in Word. Maybe someone can write a LibreOffice plugin for Parsoid, though! Would be scary, but who knows.
See https://www.mediawiki.org/wiki/Alternative_parsers for more information. Many tried and got hurt. :)

Data loss in conversion of documents from .odt to .doc

I have a plugin developed for both MS word and Open Office.
Using the open office plugin it is possible to add a set of Marked references (using XNamed) the xml in content.xml for this mark is:
-<text:p text:style-name="Standard">
<text:reference-mark-start text:name="abc"/>hello
<text:reference-mark-end text:name="abc"/>
</text:p>
when I save this document as .doc or .docx and open it in MS word, the mark reference is lost and only plain text (hello) appears. I want to be able to preserve some information like "abc" here.
Is there a way I can programatically change the xml while open office is converting it to doc format, or while ms word is opening the converted document?
Is there a way(in ms word) to "Realize" that the document being opened was created or edited using open office?
I've used C# interop to develop the word plugin and java UNO for open office.
I ended up providing a "compatibility mode" button in my plugins,for modifying the document before saving and after opening...couldnt find a better solution.