Microsoft Word File Import/Export (Book) icon

Microsoft Word File Import/Export (Book)

Maintained by Eoin Campbell
Import the contents of a Microsoft Word file into a book, splitting it into chapters and (optionally) subchapters, based on the heading styles. The file can be saved from Microsoft Word, Google Docs or LibreOffice, as long as it has a '.docx' suffix. Also supports exporting books to Word format, for round-trip editing.
Price option: Free

Supports Moodle 2.3-5.0 See all versions
Latest release: 1 year ago
Installations: 8399
Downloads (last 90 days): 1223

Frankenstyle name: booktool_wordimport
Book tools

Comments

Comments are no longer open for new posts. Existing comments remain available to read.

Thanks Eoin, I have now set the the tags to the required version and updated glossary_wordimport and everything looks good!
Hi Geoff, I have now fixed local/glossary_wordimport (v1.1.7). However, Moodle 5.0 requires an incompatible code change in question/format/wordtable, so the latest Github release (tagged v3.9.6) is for Moodle 5.0 only. You need to download v3.9.5 instead. local/lesson_wordimport relies on question/format/wordtable, so you need to download the older version from Github. local/wordimport is also updated for 5.0 to include tiny_wordimport instead of atto_wordimport (Atto has been dropped from 5.0), so again you need older version.
Eoin, Thanks for that, that's fixed that plugin... However I'm seeing the same for question/format/wordtable, local/glossary_wordtable, local/lesson_wordimport and local/wordimport. I think these are yours as well?
Sorry!
Hi Geoff, I've released a new version on Git, v1.4.14, which requires only Moodle 3.9.
Hi, I've just run a git update from the wordimport master repository, but when I try to upgrade the database I get an error that
version 2025041501 requires version 2025041400 of Moodle which fails and 2025041400 of booktool_importhtml which fails and is not available
I am running version 4.4.8+ of Moodle.
How can I correct these dependencies?
Thanks
Geoff
Yes, I think that's exactly it. Thank you, Eoin
I'm not sure exactly what you mean by "the text appears incomplete". One possibility is that paragraphs are out-dented too much, and the first few letters of each line are therefore hidden from view.
The conversion process maps named styles in Word into corresponding elements in HTML, but a bullet point in Word usually doesn't use the specific named style "List Bullet": instead it uses the generic "Normal" style, or possibly "List Paragraph". You must therefore manually set the style of bullet points to "List Bullet". An easy way to do this is to add a shortcut key for the "List Bullet" style, for example <Ctrl>+<Shift>+L, <Ctrl>+<Shift>+8, or just <Ctrl>+8. Then when you want to start a bullet list, type the shortcut key. See "How to Assign Keyboard Shortcuts to Microsoft Word Heading Styles" at https://www.msofficemaestro.com/blog/how-to-assign-keyboard-shortcuts-to-microsoft-word-heading-styles
Hello! When importing, the bullet points get messed up and the text appears incomplete. Any solution? Thank you!
Embedded videos are not supported. I think you should create a link to the video instead.
Thank you, Eoin. On another note, in the books I’m working on, it only exports partially. I have embedded a video that I took from the social network X, and everything shows up fine until that point. However, from the video onwards, nothing is exported. I’m using the
If the book content was originally created internally in Moodle, it is possible that the images were not inserted directly into the Book chapter content, but included by reference instead, i.e. using a hard link to the image, which is stored elsewhere. This would explain why the image isn't displaying on export. You don't explicitly mention what table formatting is lost, but one likely issue is that visible cell borders in Word are not retained. The best workaround for this issue is to add some extra CSS to your sites' theme (in Site administration > Appearance > Themes > Adaptable > Settings) to specify how borders are displayed.
Good day, Eoin. I am having issues with the plugin when importing/exporting. I am using Moodle 4, and the plugin version is 1.4.12 (Build: 2023021700).
When exporting the book, some images are broken, and it doesn't maintain the layout. The document only shows part of the content.
When importing, the tables lose their formatting. How can I solve these issues?
Hi Claus, you could try opening the generated file in Word, copying all the generated text, and pasting it into a new blank Word file. Then try importing the new file. If this works, then it indicates that the Word file generated directly from Python has some internal issue preventing it from being imported into a Book using the plugin. Your Python script should probably use explicit headings rather than bold-formatted text, which the plugin prefers, e.g. doc.add_heading('Heading level 1', 1)
Hi Claus, I am unable to access the file at the URL you provide. It is possible that you need to change the permissions to allow anyone access it.