-
mvpjjf
AskWoody PlusSeptember 6, 2014 at 11:04 am in reply to: Macro help: Creating text box in Word from other application #1466490I don’t have CorelDraw to play with, but this code works as a macro in Excel after setting a reference to the “Microsoft Word xx.x Object Library” (where xx.x is whatever Office version you have on the computer).
Code:Sub WordPlay() Dim wrdApp As Word.Application Dim wrdDoc As Word.Document Dim i As Integer Dim Box As Word.Shape Set wrdApp = CreateObject(“Word.Application”) wrdApp.Visible = True Set wrdDoc = wrdApp.Documents.Add ‘ create a new document With wrdDoc For i = 1 To 2 .Content.InsertAfter “Here is a example test line #” & i .Content.InsertParagraphAfter Next i Set Box = .Shapes.AddTextbox( _ Orientation:=msoTextOrientationHorizontal, _ Left:=InchesToPoints(1), Top:=InchesToPoints(2.5), _ Width:=InchesToPoints(4), Height:=InchesToPoints(2), _ Anchor:=.Paragraphs(1).Range) Box.TextFrame.TextRange.Text = “Text in box” & vbCr & “Second line” End With End Sub
-
mvpjjf
AskWoody PlusTo save a preview in every document, open the Normal.dotm template (using File > Open and navigating to the Templates folder), press F12 (the Save As command), and check the Save Thumbnail box in the lower left part of the dialog before clicking OK. Repeat for every other template that you use regularly. That will cause the same box to be checked in the dialog the first time you save every document.
If you expect to see the previews in Word’s Open dialog (or the same for workbooks in Excel or slide decks in PowerPoint) it isn’t going to work because of this long-standing bug. Since you can see previews in Windows Explorer even for documents that don’t have saved thumbnails, you might as well not bother saving them at all.
-
mvpjjf
AskWoody PlusGo to File > Options > Save and check the option “Don’t show the Backstage when opening or saving files”. Then always use the Ctrl+O shortcut, which will display the Open dialog directly. The dialog will initially show the folder that you enter in the “Default local file location” box on the same Options page.
-
mvpjjf
AskWoody PlusIt sounds like you’re only using the Preview Results button, which shows one page at a time. Click the Finish & Merge button instead, and choose either to print immediately, or to merge to a new document (the Edit Individual Documents choice)
-
mvpjjf
AskWoody PlusJune 8, 2014 at 10:56 am in reply to: Existing documents, with no macros, load with Security Warning – Macros have been disabled #1455835There are a couple of ways to find the name of the attached template by using buttons on the ribbon, but if that happens to be the Normal template then all you’ll see is “Normal” and not the folder path — not helpful. To see the full path regardless of which template is attached, follow these steps:
-
[*]Press Alt+F11 to open the macro editor.
[*]Press Ctrl+G to open the Immediate window at the bottom right.
[*]Type or paste this line in the Immediate window and press Enter:[INDENT]Print ActiveDocument.AttachedTemplate.FullName[/INDENT]
-
mvpjjf
AskWoody PlusMay 19, 2014 at 9:08 pm in reply to: Default Minimum Margin Settings for a printer (for ALL Programs) #1453568Are you using the old printer driver, the newest (October 2009) driver from HP, or the driver that comes with Windows 7? If it isn’t the newest one, download that from http://h10025.www1.hp.com/ewfrf/wc/softwareCategory?cc=us&lc=en&product=61818 to see if that improves the behavior.
-
mvpjjf
AskWoody PlusRandyMc: To clear up a possible misconception: Selection.Fields(1) does not mean the same thing as ActiveDocument.Fields(1). Instead, Selection.Fields(1) refers to the first field of which any part is contained in the Selection. If the Selection happens to be in the 15th field in the document, then Selection.Fields(1) and ActiveDocument.Fields(15) are the same field. Paul’s code uses the same idea, except that it mentions the .Fields(1) of a Range object.
-
mvpjjf
AskWoody PlusMay 8, 2014 at 12:25 pm in reply to: Want left bar in margin to work like change tracking (Word 2010, PC) #1452325I’d like to add a comment on why Andrew’s answer is the best solution.
In order to create a vertical bar in the margin next to a table without using tracked changes, you would have to insert a line Shape with text wrapping other than in-line. You would have to calculate the length of the line to match the height of the changed matter, which is not a simple job if there are non-text elements, multiple paragraphs with different Space Above/Below settings, various font sizes, etc. Once all that’s done, there is no good way to lock floating shapes against being dragged — only their anchors can be locked.
Using real tracked changes avoids all this agita.
-
mvpjjf
AskWoody PlusRight-click a text file and click Open With. Assuming UltraEdit doesn’t appear in the list (it didn’t for me, either), click “Choose default program”. If you still don’t see UltraEdit, click “More options”. It probably won’t be in the expanded list, either, so scroll all the way to the bottom and click “Look for another app on this PC”. Then you’ll get the standard Open dialog, where you can navigate to the folder (in my case, C:Program Files (x86)IDM Computer SolutionsUltraEdit-32) and click on the executable file uedit32.exe, then click the Open button.
That makes UltraEdit the default program for .txt files — they’ll display the UltraEdit icon, and double-clicking the text file will open it in UltraEdit. The program will also appear in the Open With list on the right-click menu, but only for .txt files and not for other types.
There’s also a File Associations category in the Advanced > Configuration dialog inside UltraEdit, but I haven’t been able to make it do anything on Win8.1.
-
mvpjjf
AskWoody PlusIf all else fails, here’s an old article showing how to use a page break in an IF field to force a blank even page at the end of a chapter — you don’t need section breaks if you use this.
If you want the blank page to be completely blank, don’t put the “This page is intentionally blank.” statement into the field; leave just the page break between the quotes.
-
mvpjjf
AskWoody PlusFebruary 22, 2014 at 12:42 pm in reply to: Where are all the internal linkages and references documented? #1440554I have a problem with an older pc that will take manual fixing.
Plug and play is not recognising anything.
I will have to go into the registry and put in the devices.
Then point to the drivers somehow.
Insert the drivers somewhere.
And who knows what all other links and references windoze uses.With 25 years of experience in writing Windows installation packages, I can guarantee that you won’t be able to fix USB or other OS-related problems by making manual changes in the registry. Besides the dozens to hundreds of barely documented entries you’d need to deal with, there are entries that Windows won’t allow you to edit.
The only way to fix those problems is to reinstall at least the drivers, and possibly all of Windows as mrjimphelps described, using the official installers.
-
mvpjjf
AskWoody PlusIt isn’t clear what “primarily located” means in this case. The executable files for the Office programs will be found in C:Program FilesMicrosoft Office 15rootOffice15.
If you want to know about other major locations, list the ones you’re interested in. Many of them (e.g., the default document folder and the default template folder) can be configured per user through the Options dialog in each program.
-
mvpjjf
AskWoody PlusFebruary 15, 2014 at 8:14 pm in reply to: Problems with Office 2003 and 2010 together plus new email #1439236What I’m wondering is this: If I remove Office 2003 via the control panel, will that cause havoc with my 2010 installation? I’d like to keep some of the macros and dot files I used with Word 2003, but I’m not quite sure where they’re hidden. I’m also not quite sure if 2010 uses ACL files or where to find my old ones.
While mrjimphelps’ advice to uninstall both versions and then install only 2010 will do the job, it shouldn’t really be necessary. You can uninstall Office 2003, and then run a Repair of 2010 (in the Control Panel | Programs and Features, click on Office 2010 and click Change at the top of the window, then select Repair on the first page of the wizard). That will make sure the registry entries are correct for matching document types with default programs.
Uninstalling Office 2003 will not remove any of its documents, templates, macros, AutoCorrect entries, or add-ins. They’ll still be available for use in Office 2010. You should find the templates in the folder %appdata%MicrosoftTemplates, which Word 2010 also uses. Similarly, Word 2010 uses the same ACL files for AutoCorrect; you’ll find them in %appdata%MicrosoftOffice.
If you make a new document in Word 2010 based on a .dot template from Word 2003, it will say “Compatibility Mode” in the title bar, and some of the features of Word 2010 will be disabled. To fix that, open the template file itself (from File > Open), click File and click the Convert button, then save the template as a .dotx (non-macro) or .dotm (macro-enabled) template.
Most macros written for Word 2003 will work as is in Word 2010. The exceptions are mainly ones that work with or modify the menus and toolbars, which don’t exist in Word 2010, and ones that use the FileSystemObject (see http://www.mrexcel.com/forum/excel-questions/643288-excel-2010-visual-basic-applications-replacement-application-filesearch.html for a replacement).
-
mvpjjf
AskWoody PlusYou can change the behavior of Win 7’s Explorer to fix the first problem (expanding the folders in the left pane): Click Tools > Folder Options. On the General tab of the dialog, check “Automatically expand to current folder” and click OK.
I see the “jumping away” behavior, and I don’t know of any fix for that.
-
mvpjjf
AskWoody PlusWhy are you stuffing everything into a collection and then pulling it out again? It’s more efficient (and has fewer mysterious problems) if you just transfer each piece as you find it.
There are other things here to think about. First, using Selection.Find forces Word to scroll and render pages, which slows the execution — often by an order of magnitude. Instead, use a range object’s .Find, which doesn’t cause any scrolling. Second, your pasting would put all of the found items one after the other, without any intervening space or paragraph mark. Third, each pasted item will end with an incomplete tag, just the left bracket and the slash.
Try this replacement:
Code:Public Sub GenerateDocument(Tag As String) Dim createdDocument As Document Dim rg As Range ' Dim destRg As Range ' see "alternatively" comment below Set rg = ActiveDocument.Range Set createdDocument = Application.Documents.Add ' Set destRg = createdDocument.Range On Error GoTo err: 'find all the matching bits With rg.Find .Text = "[" + Tag + "]*[/" .Forward = True .Wrap = wdFindStop .Format = False .MatchWildcards = True While .Execute createdDocument.Range.InsertAfter rg.Text & vbCr ' alternatively, to include formatting: ' destRg.FormattedText = rg.FormattedText ' destRg.InsertAfter vbCr ' Set destRg = createdDocument.Range ' destRg.Collapse wdCollapseEnd Wend End With Exit Sub err: MsgBox "GenerateDoc: " & err.Desciption End Sub
![]() |
Patch reliability is unclear. Unless you have an immediate, pressing need to install a specific patch, don't do it. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
CISA warns of hackers targeting critical oil infrastructure
by
Nibbled To Death By Ducks
5 hours, 30 minutes ago -
AI slop
by
Susan Bradley
4 hours, 40 minutes ago -
Chrome : Using AI with Enhanced Protection mode
by
Alex5723
6 hours, 46 minutes ago -
Two blank icons
by
CR2
13 hours, 16 minutes ago -
Documents, Pictures, Desktop on OneDrive in Windows 11
by
ThePhoenix
15 hours, 40 minutes ago -
End of 10
by
Alex5723
18 hours, 21 minutes ago -
End Of 10 : Move to Linux
by
Alex5723
18 hours, 50 minutes ago -
Single account cannot access printer’s automatic duplex functionality
by
Bruce
15 hours, 19 minutes ago -
test post
by
gtd12345
1 day ago -
Privacy and the Real ID
by
Susan Bradley
14 hours, 29 minutes ago -
MS-DEFCON 2: Deferring that upgrade
by
Susan Bradley
6 hours, 35 minutes ago -
Cant log on to oldergeeks.Com
by
WSJonharnew
1 day, 4 hours ago -
Upgrading from Win 10
by
WSjcgc50
6 hours, 5 minutes ago -
USB webcam / microphone missing after KB5050009 update
by
WSlloydkuhnle
23 hours, 49 minutes ago -
TeleMessage, a modified Signal clone used by US government has been hacked
by
Alex5723
1 day, 20 hours ago -
The story of Windows Longhorn
by
Cybertooth
1 day, 8 hours ago -
Red x next to folder on OneDrive iPadOS
by
dmt_3904
1 day, 22 hours ago -
Are manuals extinct?
by
Susan Bradley
9 hours, 49 minutes ago -
Canonical ditching Sudo for Rust Sudo -rs starting with Ubuntu
by
Alex5723
2 days, 7 hours ago -
Network Issue
by
Casey H
1 day, 18 hours ago -
Fedora Linux is now an official WSL distro
by
Alex5723
2 days, 19 hours ago -
May 2025 Office non-Security updates
by
PKCano
2 days, 19 hours ago -
Windows 10 filehistory including onedrive folder
by
Steve Bondy
2 days, 21 hours ago -
pages print on restart (Win 11 23H2)
by
cyraxote
1 day, 22 hours ago -
Windows 11 Insider Preview build 26200.5581 released to DEV
by
joep517
3 days ago -
Windows 11 Insider Preview build 26120.3950 (24H2) released to BETA
by
joep517
3 days ago -
Proton to drop prices after ruling against “Apple tax”
by
Cybertooth
3 days, 7 hours ago -
24H2 Installer – don’t see Option for non destructive install
by
JP
1 hour, 5 minutes ago -
Asking Again here (New User and Fast change only backups)
by
thymej
3 days, 18 hours ago -
How much I spent on the Mac mini
by
Will Fastie
1 day, 2 hours ago
Recent blog posts
Key Links
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.