This blog is a cross between a scrapbook and a diary. I hope you find something here of interest. If you’d like to keep up with things as I see them then you can subscribe to my news feed by clicking the icon below:
Please note that any reviews/recommendations are based solely on my own experience and does not constitute a guarantee that you will have the same experience. Please do your own research before parting with any money - the risk is all yours!
But only a little. I create shortcuts using VBA all the time and - up till now - I thought that the only extra field which was possible to display information about the target was “Description”, so I was surprised to see a shortcut which I created manually (just in Windows Explorer) showing the title field from the target file. [Read More…]
Occasionally you may receive a Folder In Use message such as “the action can’t be completed because the folder or a file in it is open in another program” when you try to rename or delete/move a folder in Windows 7.
There are a number of suggestions out there which might work for you, but try my suggestion first and you may be pleasantly surprised. [Read More…]
For anyone who has a problem trying to save a Word 97-2003 Document (this may apply to other Office file types too) in Office 2010, specifically where you receive a message saying “The save failed due to out of memory or disk space” then there is an easy fix for this. [Read More…]
Having finally been forced to use Windows 7 on my computer at work I was faced with the loss of a couple of handy features which I’d become accustomed to in Windows XP.
One such problem concerned the apparent inability to show more than the barest of information in the little popup you get when you hover your mouse cursor over a file in Windows Explorer in Windows 7.
Actually that’s only partially true - it still works for local files (e.g. files on your own hard drive) but for files viewed on a network drive - whether mapped to drive letters of not - you only see the file type, last modified date, and it’s size, none of which is really worth the effort of showing the InfoTip in the first place (you can turn the feature off in folder options).
However it IS possible to get all of the extra information that might be stored in the File Properties (e.g. the document title, subject, and comment) by making a simple change to the registry. Here’s an example of how it looks in Windows 7 - you can see there how useful it is to show more information than you can easily display in the columns to the right:
WARNING! It is also assumed that you are familiar with the Windows Registry and are happy about taking the risk that you could seriously screw your day up if you do something wrong in there. If not then stop right here and go fetch someone who is. For this reason the instructions below are written with less detail than I would normally provide.
If you’re not confident about doing this then please stop right here!
Otherwise, here’s how to do it:
1) Click on the windows button (normally at the bottom left of your screen) and then type “regedit” in the “Search programs and files” box, then hit return.
2) RIGHT click once on the regedit.exe file you should see in the box above the search box and choose “Run as administrator”. REMEMBER - don’t try this unless you know you have administrative rights to the computer - if you know you can install new programs, then you’re probably going to be ok - if not, then you’ll probably be wasting your time doing what comes next because Regedit won’t let you save your changes after all your efforts.
3) Go to HKEY_LOCAL_MACHINESOFTWAREClasses* and add the following to the end of the existing values in both InfoTip and QuickTip:
Type (or copy and paste) everything in blue - don’t forget the semi-colon at the beginning of the line as that’s the “follow on” from the entries which you’ll already find there.
The reason you need to change it in both keys is that Windows will prioritise “QuickTip” over “InfoTip” when you hover over a network file. Microsoft did that in case you are viewing files over a slow network connection, so it’s useful to know you can make that little tweak if your computer slows to a crawl trying to display the popup information.
In some cases (for local files) I also needed to change the InfoTip value in HKEY_CLASSES_ROOTSystemFileAssociations - for instance, for my Word docs (my VBA only generates 2003 versions of Excel and Word files) I needed to make the same change to the InfoTip in HKEY_CLASSES_ROOTSystemFileAssociations.doc
4) Close regedit.
It should be enough, at this point, to simply close and re-open Windows Explorer in order to see the effect of your changes, or you might want to log off and back on to Windows just to make sure.
My other problem (I’m sure I’ll find more - I won’t even mention my hatred of ribbon menus) is the sad loss of the Folder Description column I could add which allowed me to add a comment to a folder using a truly excellent program called HobComment. While this may still work for 32-bit versions of Windows it certainly doesn’t in 64-bit editions but, fortunately, all is not lost!
In my case I still have my old Windows XP PC connected to the network so I simply access this via RealVNC and add my comments there. Displaying the folder description in a column in Windows 7 is actually a piece of cake - simply right click on the column headings in Windows Explorer and add “Comments” column :) Curiously that trick DOESN’T work in XP, but who cares? Here’s how I’ve got it looking in Windows 7:
In case you don’t have an XP machine which you can use to add your folder comments then all is not lost because you can run XP on your Windows 7 computer in order to run old programs like HobComment, by using Microsoft’s very own Windows Virtual PC. I haven’t tried this yet, but I’m sure it will work.
Sometimes you may find that the minimum font size offered to you by Adobe Acrobat when adding a text box to a PDF document is still too big for your needs. Luckily it’s very easy to get around that problem. Here’s how to do it… [Read More…]
When you open an Word document from an email and start making changes to it, it’s easy to forget that you’re only editing a “temporary” document. If you save your changes it’s often quite difficult to find your revised document again.
To help avoid that here’s a nice snippet of VBA code which you can use to issue you a warning message every time you open a document from an email, like this:
As a kind of “bonus” the following script will also warn you if the document you are opening has tracked changes enabled, and ask if you want to turn them off.
To install the code open up Word and press Alt+F11 to get into the Microsoft Visual Basic Editor.
In the left hand pane under “Normal” double click “Microsoft Word Objects” then double click “ThisDocument”, and enter the following code in the pane on the right. It should all look something like this:
And here’s the code to put in there. Please note that you’ll need to remove the apostrophe from the beginning of the line saying ‘MsgBox(ActiveDocument.Path) and then open an document from an email in order to find out and jot down the Windows file path of your temporary folder, which you need to enter later in the code. I figure if you’ve been brave enough to go this far then this step should be plain sailing for you :)
Private Sub Document_Open() ' the following code will determine if the document you are opening ' has tracked changes enabled and ask if you want to turn them off ' it will also warn you if you are opening a document from an email ' in case you intend making changes to it Dim TurnOffTrackedChanges As Variant ' Uncomment the following line and open a Doc from an email to find out what your temporary folder is 'MsgBox(ActiveDocument.Path) If ActiveDocument.TrackRevisions = True Then TurnOffTrackedChanges = MsgBox("This document has tracked changes enabled." & vbCrLf & vbCrLf & "Do you want to turn tracked changes off?", vbYesNo, "WARNING - Tracked changes enabled!") If TurnOffTrackedChanges = vbYes Then ActiveDocument.TrackRevisions = False MsgBox ("Tracked changes have been disabled :)") End If End If ' You need to put your temporary folder name below - uncomment the message box at the top to find out what it is 'example for WinXP If ActiveDocument.Path = "D:Documents and SettingsPaulLocal SettingsApplication DataOperaOpera 11.64temporary_downloads" Then ' Example for Win7 'If ActiveDocument.Path = "C:UsersLee CliffordAppDataLocalOperaOperatemporary_downloads" Then MsgBox ("WARNING! You may have opened a temporary copy of this document from an email as the current file path is" & vbCrLf & vbCrLf & ActiveDocument.Path & vbCrLf & vbCrLf & "If you intend making any changes you should save it RIGHT NOW to a different location... or you could lose your changes!"), vbCritical End If End Sub
Unless you’re familiar with Word documents which have tracked changes enabled it can be a bit confusing when you start editing such a document and everything you type is in red and underlined. Unless you know why this is happening you might waste a lot of time re-formatting everything you type.
Fortunately there IS a way to automatically detect if the document you are opening has tracked changes enabled, and pop up a box asking if you’d like to turn this feature off. Here it is. [Read More…]
Making full use of the document properties sheet for a Word document (or any document) is not only good practice but it’s more useful than you might at first think because you can use this information in a number of ways, not the least of which is to simply see what the document is about without having to open it, often simply by hovering your mouse over the file name in Windows Explorer…
Setting the document properties is a bit of a chore, to be honest, and busy people tend to follow the line of least resistance… and just ignore it. Even though some companies insist that their staff use the document properties to enable the documents to be more easily searched and sorted, it’s a difficult thing to police.
Here’s a much easier way to set the document properties which really is as simple as selecting some text and doing a simple keystroke. This example shows you how to set the document’s “Subject” field. [Read More…]
[updated May 2015 - VBA code updated to check for a hyperlink in a table cell, and just remove the white space from the displayed text while leaving the hyperlink intact]
It may happen that you need to remove white spaces from the ends of lines in Word documents - not just in the main text, but in table cells too.
Removing white spaces from the ends of lines in normal paragraphs is relatively easy - just do a find and replace of ” ^p” (that’s a space followed by the “hat” character which you can usually get by typing Shift+6) followed by a p, with “” (nothing). “^p” stands for the paragraph mark, or pilcrow (¶) which you can see if you show all of the non-printing characters in your document.
This will instantly rid your document of all those unwanted spaces. But what about the same thing in table cells? For this we need to box a bit cleverer. [Read More…]