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.

Hello... We have installed this plugin and always get an error message, referred to the treatment of images, when we try to export a book to doc. Error messages are like:
booktool_wordimport_base64_images: chapter file: .
line 471 of /mod/book/tool/wordimport/locallib.php: call to debugging()
line 109 of /mod/book/tool/wordimport/index.php: call to booktool_wordimport_base64_images()
booktool_wordimport_base64_images: chapter file: IMG_5004 OK.jpg
line 471 of /mod/book/tool/wordimport/locallib.php: call to debugging()
line 109 of /mod/book/tool/wordimport/index.php: call to booktool_wordimport_base64_images()
We have tried it in two diferents server and always the same error. We are using Moodle 3.3+ (build 20170525), Ms Word File export / import version 1.2.5 (the latest one) and PHP xsl version 1.1.28 installed and enabled.
Thanks in advance for your time...
Best regards.
Support for images is good but not great. The image dimensions and any alternate text are retained on import, but positioning and cropping information is not. You need to do any image manipulation outside Word, and insert the final image into Word, before importing into Moodle.
Hi. I have imported a .docx from Word for Mac 2017, and the headings, etc worked. However, I positioned images and cropped some, and these all failed. The position data is lost, whilst any cropping has been removed, so the whole image re-appears. No idea if you are able to address this, but it'd be excellent if you could.
that's great many thanks
HowtoMoodle have given me a fix and I have implemented it and released version 1.2.4 which should resolve the issue.
Hi,
I'm getting a similar error when I try to import my document. We're using Moodle 3.2.5. I have tried the same document on your Book Sandbox course and it worked fine (see http://www.moodle2word.net/mod/book/view.php?id=68 ) but when I use the the same file on our site I get this:
Word import test
Import from Microsoft Word
Cannot read file. Either the file does not exist or there is a permission problem.
More information about this error
Debug info: /tempup_edMuMP.zip
Error code: storedfilecannotread
Stack trace:
line 1951 of /lib/filestorage/file_storage.php: file_exception thrown
line 1508 of /lib/filestorage/file_storage.php: call to file_storage->add_file_to_pool()
line 145 of /mod/book/tool/wordimport/locallib.php: call to file_storage->create_file_from_pathname()
line 140 of /mod/book/tool/wordimport/index.php: call to booktool_wordimport_import_word()
any ideas? I'm sending this to HowtoMoodle support too (our host) so will let you know if they come up with anything.
many thanks
Isabel
This could be anything really. Perhaps the file is not in the correct format (.docx), the filename contains forbidden characters, the file contents contains non-Unicode characters, or most likely, your Moodle installation might have temporary folders with incorrect permission settings. Try importing the file on www.moodle2word.net in the "Book Sandbox" course to rule out some of the issues.
Hello,
I continue to have this error:
"You can not read the file, the file may not exist or there may be problems with the permissions"
Can I request your help?
Thank you.
I think the probable reason for this error is that there is a character somewhere in your Word file that is not Unicode-compatible, and therefore the converted HTML cannot be inserted into the MySQL database. "Incorrect integer value: '/index01.htm'" is confusing me though, so it is also possibly related to a formatting problem in one of your "Heading 1"-styled headings. The headings should not have any formatting overrides applied to them. You can remove such overrides by selecting the heading and pressing <Ctrl>+<Space>.
Hello, We have installed the plugin but get an database SQL error as follows:
Default exception handler: Error writing to database Debug: Incorrect integer value: '/index01.htm' for column 'importsrc' at row 1\nINSERT INTO mdl_book_chapters (bookid,pagenum,importsrc,content,title,contentformat,hidden,timecreated,timemodified,subchapter) VALUES(?,?,?,?,?,?,?,?,?,?)
What could be the reason?
We are using Moodle 3.1
Thanks, in advance for all the help.
Regards,
Adi
Hi Tran, the facility to upload a file is in the Book administration menu (see screenshot above). If the "Import from Microsoft Word" command is not present, then the plugin is not installed on your server. You can try it out on my test server at www.moodle2word.net too.
please!! help me!!! I can't upload file *.docx
Thank you for the swift reply , I send in a direct message.
Hi Avi, thanks for trying out the plugin. Here are some responses.
1. Footnotes. What would you prefer to happen: a) footnotes are silently deleted; b) footnotes are linked, and placed at the bottom of the page, or c) footnotes are embedded where they occur (in brackets)?
2. Headings not imported properly. This problem is caused when the default formatting of the heading is overridden. If you select the entire heading, and press +, this removes all overrides, and the heading should then import properly.
3. First section not imported. I'll take a look at this issue.
4. Templating and Activity. I don't know what you mean here, can you explain further? (Send me a direct message).
Thank you very much for this plugin. I installed it on our test - server running moodle 3.3 . I do have a few questions or requests if you can help us.
1. when importing a docx file. footnotes are embeded into the text which causes a lot of work.
2. headings are nor imported (from hebrew) and are stated as index00.htm index001.html ...
3. when docx numbered, the non-numbered front page is not imported.
I know that this plugin is good even very good but it could become better with templating & activity set in. (could be as a sub-course) .
Again thanks for the work