It’s still coming along (v1.89)

In all honesty, I thought I’d finished it a few weeks ago when I last posted onto the blog. But then I’ve been doing some digging around in the code finding all kinds of weird and wonderful bug-ettes. Daft things like deleting the default Windows folder for Word templates but leaving the Mac one behind. What a plonker!

Feedback had been received about the Image/Shape Browser from David Green, so that needed fixing too. And whilst I was fixing it, I was also improving it based on some of his suggestions, plus adding my own bits in.

I think I’m finally on the last stretch as there’s just an annoyance has crept into the Configuration form to fix. I keep getting ‘ghost’ items in the list when you delete one item, it removes it fair and square. But then leaves an empty row in the array, when all the code should be doing is removing it. *head scratch time*. I think it’s something I’ve done when I did a search and destroy on lots of Public variables which should be Private variables and that’s caused a few issues elsewhere. Time to dig out the last known working version of the code and compare it against the new one, line by line …

In other sort of related news. I spotted a bug in the excellent MZ Tools, so there will be an update due out soon for that which includes a fix for what I found. Nice to be able to help out someone whose utility has made the job of coding this add-in that little bit easier.

Gearing up for v1.89 to be released

The add-in is being prepared ready for the next full release. Which means webpage edits and screenshot changes galore as I’ve moved from Office 2013 as my main development tool to Office 2016. If you’ve tried any of the beta versions out, you will have noticed that the screenshots in the manual are now based on the newer version of Office.

From its early days of just being a collection of unlinked single functions carved into an ever bulging Normal.dotm file, through to what you have now: a full GUI-based system which lots (and lots) of functions.

It’s been two years of on/off development for the add-in. The first post on this blog was written back in August 2014, but the coding of the ‘GUI-based version’ had started in earnest a month or so before-hand.

I’ll sort out a proper “What’s New” post on the day of release so that those who haven’t downloaded any beta versions before will be fully aware. The list of bug fixes is large as well, but I’ll leave that detail in the manual as wouldn’t want to bore anyone with that.

After these two years, I’m happy to say that this add-in is still 100% free – and that includes the fully commented source code.

New beta (v1.88h) now available

This is just an interim beta release as I’ve fixed a few bits here and there, but I’m still not sure whether I like how the add-in is handling endnotes and footnotes. I’ve added the detection of Whole Document / Selection to the form so that if you only want to amend endnotes/footnotes in a particular area, highlight it first before launching the Endnote/Footnote Inspector tool.

Grab it from the Beta download page and, for those who use endnotes and/or footnotes in your documents, please do your best and test out the functionality with this beta.

In other news, this add-in has to be developed at home and not in work. In fact, it has been for a good 6 weeks or so, but the lack of any real progress shows just how much I prefer relaxing with my Xbox One when I’m at home. Far Cry 4 was recently completed and I’ve just started Mad Max, so I’ve no idea when the next full release of the add-in will appear 🙂

Still working on endnotes/footnotes (v1.88g)

I’m getting there (honest), but it’s a slow plod as each new idea I come up with to add to the code, either doesn’t work quite as I’d hoped it would, or isn’t much better than what’s Word already has built-in. Just my routines are easier to find 🙂

Here’s the endnotes inspection tool:

endnoteinspector

And, looking very similar (*), here’s the footnotes inspection tool:

footnoteinspector

(*) Copy and paste code/form design? Not me!

It is very confusing the way that Word treats endnotes that are stored at the ‘end of the document’ as an extra copy of itself.

E.g. I use the VBA command: ActiveDocuments.Endnotes.Count to work out how many I’ve got in the current document. It tells me that there are two of them. However, if I change the second copy of the only actual endnote, so that it is stored at the ‘end of the section’ and then refresh my form, the ‘spare’ one disappears!

Ergo, more work is needed before I can release the beta of v1.88g.

Which will appear on the new Beta Version page – which is now live.

v1.88f will be due out soon

I’ve been shaving off a few bytes here and a few bytes there. This has entailed all kinds of VBA jiggery-pokery: changing Public vars into Private/Local vars, creating more code here and there – just so that I can delete the multiple existences of it elsewhere and all other kinds of tweaks.

But then I realised that whenever I do release v1.89, there aren’t going to be that many new bits to blow the trumpet about! So I’ve given up on the byte-squashing and decided to concentrate on adding new features.

Since the last beta was issued, I have added:

a) The ability to change the font size (8 through to 12 point) of the text that appears in the Fix Footer Into Table routine. It will still use whatever font is associated with your Normal style though.

b) The same languages that are supported under the Fix Language function are now also recognised when they are used in a Word template. Not a major addition, I grant you, but there wasn’t much code that needed adding to get the same recognised range working.

c) The Odd/Even Header/Footer toggle is now out of the Section Inspector (which has had more layout tweaks since the last beta) and back into the Footer Information area of the Toolbox. At least it now applies to the whole document and not, as I originally thought, was toggled each section.

d) Within the Section Inspector you can now toggle the page orientation of the current section. This was done especially for a particular set of documents where I work. Makes life easier when fixing the orientation anomalies 🙂

e) Along with the ‘Reset Table Styles To x’ feature, there’s a ‘quick fix’ button which will reset any of the selected tables to plain old boring ‘Normal’ style. A handy fix for when you just want to undo whatever someone else’s done to a table 🙂

f) Also within the Table Inspector, you can now delete empty rows or delete empty columns from selected tables. Again this is one of those ‘can you add this feature’ request from an existing user. More than happy to oblige 🙂

There’s probably other tweaks which have been done and I’ve forgotten about. I’m hoping to get some basic functionality to cover endnotes and footnotes before I release v1.89, but as with all things with this Toolbox, it all depends on how much free time I have.

I will upload v1.88f to the usual DropBox locations early next week (all being well). If anyone wants them uploading to Google Drive, I will do that as well. Especially for those who work in a company where brand x of cloud storage is banned, but brand y isn’t 🙂

Lack of blog updates, but not coding changes

Shortly after the full version of v1.87 was released, a regular user pointed out a few anomalies in my Section Inspector tool.

After a few beta-versions were sent back and forth, and a complete overhaul of how the Section Inspector form layout looked, I now felt much happier with it. Some of the tweaks were also applied to other forms that use listboxes as well, which enables/disables functions based on what is or isn’t selected in the list box.

I released a v1.88c last week to the beta URL but I’m still tinkering with how it works, so expect a v1.88d in the next few weeks. I’ve also been trying to get more features in, but with some optimisations at the same time so that the file size of the add-in doesn’t increase too much.

The main reason for the lack of blog updates is plain and simple: Weebly.com, and a whole host of other useful sites, are now blocked from being accessed where I work.

Along with DropBox, Gmail and a few other useful sites. Turns out someone had allowed everyone access to these sites by accident, so whilst it was good for a while, the whole thing has now been very much screwed down and limited.

There’s other problems with Firefox that are also causing sites to be blocked, but I’m not that up on the whys and wherefores, other than it’s a PITA to find once useful sites are now blocked/classed as dodgy. Ho hum.

New full version available (v1.87)

I was hoping to get this version out nearer to my 46th birthday, but c’est la vie. Officially I will release this tomorrow via a LinkedIn post, but for those of you reading this on Twitter, you can grab a copy – a day early 🙂

This version has lots of new features and quite a few changes (some forms and tabs have been removed and/or merged) but all-in-all, there’s lots of good stuff.

One of the major changes (that hasn’t been in previous beta version) is the new Section Inspector. This is a merger of the old Section Breaks tab in the Toolbox, some of the fields from the Additional Information tab too and some extra functionality – all in one form. You now have much better control over the sections in your document than possible before. Or, at least, that’s what I think you will have 🙂

sectioninspector_v1_87

After moving all of the above information into the one form, there wasn’t much point in keeping the older tabs. Two tabs have been removed completely with the remaining bits being moved into the Footer Fix tab. Which then, due to the ‘new’ bits, has now been renamed to Footer/Information.

footerinformation_v1_87

Other changes are that the old Back to Basics form has been removed. It had to go purely because the four things you could remove – zap headers and footers and remove Footnotes and Endnotes – were now either on the Section Inspector or the form above.

The actual size of the add-in hasn’t increased that much since the last official v1.85 either, so my code optimisation is getting better. There’s still room for improvement though 🙂

As per usual, the full source code package has also been updated to v1.87 too. If any VBA coders out there want to see how I’ve done a particular function, and can see a way to speed it up, then let me know via my Gmail, LinkedIn profile or on the Trello board. These are all listed in the About box.

Finally, it’s take to take a rest and stop tinkering with the code. I usually have a month or so to rest between a final release and the first beta version.

Fields Inspector now ready in v1.86j of my Word Toolbox

I’ve finally had some spare time in work to get the final touches done to the Fields Inspector. The old ‘Fix Fields’ routine from the toolbar has been retired.

fieldinspector_24032016

All of the 90+ possible types of field are examined and listed in the box. From here you can unlink, delete or unlock them, along with the original function that was in the previous versions of the toolbox to Reset Fields.

More options may follow, but I’m not sure what extra functions would really be needed (if I’m being honest) as I don’t really use many fields in my own documents.

Other alterations have also been made to this version. My attempt at making a ‘nice looking’ GUI for the Readability Stats has been removed. It caused problems in quite a few test documents, so I’ve removed it from the Footer tab and it’s now back to being a simple button on the first tab, Information. Due to the test documents (esp. one created by MadCap Flare), there’s some extra-strength error-checking included 🙂

As we’re moving away from RoboHelp to MadCap Flare in work, the RoboHelp function has also been removed. If I can come up with some functions to use this toolbox with MadCap Flare, I’ll put a blog post up to announce it.

Grab the latest beta (v1.86j) from this DropBox link:

https://www.dropbox.com/s/qe3hdkbmr4ynisl/MikesMacroToolbox.dotm?dl=0

Grab the updated manual from this DropBox link:

https://www.dropbox.com/s/lgqi4fm178zuuwj/Mike%27s%20Document%20Toolbox%20Manual.pdf?dl=0

Improvements to the Fix Fields function

I’ve been putting it off .. and putting it off some more, but I’ve finally made a start on the replacement for the Fix Fields routine in the Toolbox. The new function (and new icon) will be the Fields Inspector.

fieldinspector_07032016

It’s very much in the early stages but it will display all of the fields that are found in your document and the Reset Fields command which formed part of the original code is currently the only function working.

I plan to add the following options:

  1. a) Unlock fields
  2. b) Filter TOC entries On/Off (the bigger the TOC in your document, the more fields that are displayed in the list box!)
  3. c) Edit fields – although not sure about this as most of the time it’s easier for Word to be in control of this
  4. d) Other stuff 🙂

I’ll be looking for any suggestions for functions to operate on fields, but please specify which particular ones as there’s (currently) 95 of them that Word recognises. Even if some of them are only on Macs, someone, somewhere might want to tweak them 🙂