-
WSJon Dean
AskWoody LoungerI wrote the following code for Access 97 and have since upgraded the database to 2K. It has always worked fine, though it can be slow, and you have to be careful with mapped network drives as they can cause another Access to start.
The letters themselves are mail merge linked from Word to a standard query in the database, and all have a AutoOpen macro which specifies the document name. Is this a good way to do it? Would another method be quicker?This first procedure sets the path for Word and the letters to be used.
Public Sub WordandDocPaths()
WordLocation = “C:Program FilesMicrosoft OfficeOfficeWINWORD.EXE”
DocLocation = “server1group datadatabasesDCDATA”End Sub
This procedure determines whether or not Word is already running. If No, word is started and the appropriate letter loaded. If yes, the current instance of Word is used.
Sub openletter()
Dim wrd As Object
On Error Resume Next
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
Set wrd = GetObject(, “Word.Application”)
If Err.Number 0 Then
Call Shell(WordLocation & ” “”” & DocLocation & StdLet, 1)Else: wrd.Documents.Open DocLocation & StdLet
wrd.wdWindowStateNormal = 0
End IfAppActivate (“Microsoft Word”)
Set wrd = Nothing
End Sub
Each button on the form has the following code to set the value of stdlet so the correct letter is loaded:
Private Sub CommandGeneralLetter_Click()
On Error GoTo CommandGeneralLetter_Click_ErrStdLet = “ack0.doc”
Call WordandDocPaths
Call openletter
CommandGeneralLetter_Click_Exit:
Exit SubCommandGeneralLetter_Click_Err:
MsgBox Error$
Resume CommandGeneralLetter_Click_ExitEnd Sub
-
WSJon Dean
AskWoody LoungerCharlotte
Once again you are spot on. Many thanks -
WSJon Dean
AskWoody LoungerHi
Go to http://www.fmsinc.com/free/utilities/index.html and download the Jet4Admin utility. -
WSJon Dean
AskWoody LoungerI am getting the same problem trying to put a Word 2000 doc into an Access 2000 form. The same message appears on all 4 of my office computers. In another company where I am currently working, there is no problem so, acting on a complete hunch, I have replaced the contents of C:Program FilesCommon FilesSystemOle DB with the files from a machine where OLE works. Hey presto! My OLE now works fine
Woops! In the time it took me to type the above, OLE has gone belly up again -
WSJon Dean
AskWoody LoungerHi
There are two reasons why controls do not shrink when you tell them to:
1 The controls are overlapping – check all the “Top” and “Height” properties and make sure there is a small gap between (It only needs to be 0.5mm);
2 There are other controls on the same lines as these. Since the Can Shrink property operates across the entire width of the report, these other controls will prevent your address fields from shrinking. The solution here is to put your address fields into a sub-report with Can Shrink set to yes on all the controls and the section. They can then shrink within their own report and will not be affected by other controls in the main report. -
WSJon Dean
AskWoody LoungerOk So you should have 3 tables: Inventory, Employee and Register. The Inventory table holds details of the stock items (ID, Description etc), the Employee table has ID, Name, Position, Department and stuff like that. The Register table records the logging out and in of inventory items by employees so will include Inventory ID, Employee ID, Date/Time Out, Date/Time Returned.
The many to many relationship is actually between the Inventory and the Employee (An inventory item is used by many employees, an employee uses many inventory items). The Register is your link table. It has a many to one relationship with both Inventory and Employee so an Inventory item can be logged out and in many times but each time by only one employee. Similarly, each employee can log out many inventory items but each log out can only be to one employee (you can’t have two people using the brush at the same time). So you should have three tables (Inventory, Register and Employee) and the one-to-many relationships are Inventory/Register and Employee/Register.
I sincerely hope that helps. You could also benefit from reading info about normalisation of data structures. I do have a couple of Knowledge Base documents on this if you think it might be helpful. -
WSJon Dean
AskWoody LoungerMore information is needed. You talk about material and tools and yet your tables are inventory and register. What’s the connection?
Many to many relationships are resolved exactly as MarkJ has illustrated but more specific information would yield a better solution for your problem -
WSJon Dean
AskWoody LoungerSomehow I just knew that was going to be the answer. Thanks Charlotte
-
WSJon Dean
AskWoody LoungerWhat serious problems would they be? I use non-automatic keys quite often and if I’m heading for trouble I’d like to know about it.
-
WSJon Dean
AskWoody LoungerTo all on this particular thread:
Charlotte is right about the compacting issue and potential holes in the autonumber sequence so here’s some ideas:
1 Compact before you archive. This may be impractical so;
2 Don’t take the Autonumber key with the record when you archive it (or even return it to live). This way, Access will automatically generate a new, unique key everytime a record is added to a table. This does mean that the record changes key when you archive it but since the autonumber’s purpose is purely to maintain uniqueness, this shouldn’t be a problem. If it is;
3 Don’t use Autonumbers for your key fields. Use a manually entered number or text field. You can write a bit of VBA to automatically generate the next number in a data entry form to save having to constantly try to remember what the last number was but you can change it to any unique number. This last method means your key fields are kept intact no matter how many times the record changes tables. -
WSJon Dean
AskWoody LoungerThanks for your input Charlotte. It’s nice to know somebody cares! I’m finding a few Win 2000 issues but the bios I’d forgotten about.
-
WSJon Dean
AskWoody LoungerThanks for the reply Charlotte. The more I think about this, the more I think it’s a Windows 2000 issue rather than Access since everything was fine under Win 98. However, just to clarify, I know it’s crazy but today all the text boxes are doing it. If I enter a day of 12 or less, the date gets screwed i.e 12/1/2001 becomes 1/12/2001. Not only does the format apparently change, but 1st December gets passed to the query when it should be 12th January. It’s as if my typing is assumed to be in American format (mm/dd/yy) which is then converted to dd/mm/yy when the text box updates.
I’ve just tried another test. If the first number I type is 13 or more, the date remains correct i.e. I type 13/12/2000, that is what is displayed and 13 Dec is (correctly) passed to the query. If the first number I type is 12 or less, the day and month are transposed i.e. 12/1/2000 becomes 1/12/2000, 1/31/2000 becomes 31/1/2000 etc. Am I making sense here? Re. one of your questions, these are unbound text boxes so there is no underlying data. My Windows Regional Settings are English (UK) with Short Date format dd/MM/yy
![]() |
Patch reliability is unclear, but widespread attacks make patching prudent. Go ahead and patch, but watch out for potential problems. |
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
-
Cant log on to oldergeeks.Com
by
WSJonharnew
3 hours, 58 minutes ago -
Upgrading from Win 10
by
WSjcgc50
5 hours, 47 minutes ago -
USB webcam / microphone missing after KB5050009 update
by
WSlloydkuhnle
11 hours, 20 minutes ago -
TeleMessage, a modified Signal clone used by US government has been hacked
by
Alex5723
12 hours, 36 minutes ago -
The story of Windows Longhorn
by
Cybertooth
21 minutes ago -
Red x next to folder on OneDrive iPadOS
by
dmt_3904
14 hours, 35 minutes ago -
Are manuals extinct?
by
Susan Bradley
4 hours, 4 minutes ago -
Canonical ditching Sudo for Rust Sudo -rs starting with Ubuntu
by
Alex5723
23 hours, 43 minutes ago -
Network Issue
by
Casey H
10 hours, 48 minutes ago -
Fedora Linux is now an official WSL distro
by
Alex5723
1 day, 11 hours ago -
May 2025 Office non-Security updates
by
PKCano
1 day, 12 hours ago -
Windows 10 filehistory including onedrive folder
by
Steve Bondy
1 day, 14 hours ago -
pages print on restart (Win 11 23H2)
by
cyraxote
14 hours, 57 minutes ago -
Windows 11 Insider Preview build 26200.5581 released to DEV
by
joep517
1 day, 16 hours ago -
Windows 11 Insider Preview build 26120.3950 (24H2) released to BETA
by
joep517
1 day, 16 hours ago -
Proton to drop prices after ruling against “Apple tax”
by
Cybertooth
1 day, 23 hours ago -
24H2 Installer – don’t see Option for non destructive install
by
JP
16 hours, 2 minutes ago -
Asking Again here (New User and Fast change only backups)
by
thymej
2 days, 10 hours ago -
How much I spent on the Mac mini
by
Will Fastie
1 day, 10 hours ago -
How to get rid of Copilot in Microsoft 365
by
Lance Whitney
14 hours, 3 minutes ago -
Spring cleanup — 2025
by
Deanna McElveen
2 days, 16 hours ago -
Setting up Windows 11
by
Susan Bradley
1 day, 11 hours ago -
VLC Introduces Cutting-Edge AI Subtitling and Translation Capabilities
by
Alex5723
2 days, 12 hours ago -
Powershell version?
by
CWBillow
2 days, 13 hours ago -
SendTom Toys
by
CWBillow
1 day ago -
Add shortcut to taskbar?
by
CWBillow
2 days, 17 hours ago -
Sycophancy in GPT-4o: What happened
by
Alex5723
3 days, 9 hours ago -
How can I install Skype on Windows 7?
by
Help
3 days, 8 hours ago -
Logitech MK850 Keyboard issues
by
Rush2112
2 days, 15 hours ago -
We live in a simulation
by
Alex5723
3 days, 23 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.