Is this required for only your computer or others using the database? Mike's
suggestion only works on that computer. If you need to control this behavior
on other computers using the database here's some info:
Check out Application.SetOption.
'Set some database defaults found in Tools, Options
' Put in the Open event of the startup form
' Set Default Locking to Edited Record
Application.SetOption "Default Record Locking", 2
' Set Default Open Mode for Databases to Shared
Application.SetOption "Default Open Mode for Databases", 0
' Set Default Find/Replace Behavior to Start of Field Search
Application.SetOption "Default Find/Replace Behavior", 2
Application.SetOption "ShowWindowsInTaskbar", True
In the case of "Application.SetOption "Default Record Locking", 2" Default
Record Locking has three choices and the one I want is the third so, of
course, I put in 2 for the arguement. That's because it starts numbering at 0
instead of 1.
Put the above code in the Open Event of your opening form. One other strange
thing is that the database may need to be opened and closed twice on the
user's computer for the change to take effect. The first time the database
opens, it makes the changes. The second time the changes are in effect.
--
Jerry Whittle, Microsoft Access MVP
Light. Strong. Cheap. Pick two. Keith Bontrager - Bicycle Builder.
"Duane" wrote:
>
> Philip - thanks for your efforts. However I was trying to CHANGE the
> default settings - not access them. Mike (post below) was able to answer my
> question.
> Thanks again for your efforts.
> Duane
>
> "Duane" wrote:
>
> > Access 2007- - - Can someone help me to change the default setting when doing
> > a search? I would like to change the default "Match" field FROM - "Whole
> > Field" TO - "Any Part of Field".
> > >
> > > Many thanks to anyone who can help - -Duane
> >
|