CreateNewWorkgroupFile Method [Access 2003 VBA Language Reference]
Creates a new workgroup file so that a user can securely access a database.
expression.CreateNewWorkgroupFile(Path, Name, Company, WorkgroupID, Replace)
expression Required. An expression that returns one of the objects in the Applies To list.
Path Optional String. The path of the new workgroup file. If the path is invalid, an error occurs. Default is an empty string ("").
Name Optional String. The name of the user creating the file. Default is an empty string ("").
Company Optional String. The company of the user creating the file. Default is an empty string ("").
WorkgroupID Optional String. The name of the workgroup. Default is an empty string ("").
Replace Optional Boolean. Specifies whether to replace the workgroup file in the directory specified by Path if it exists already. Default is False.
If a workgroup file already exists in the directory specified by Path, and Replace is not True, an error occurs.
This example creates a new workgroup file in the specified directory with the specified user information. If a workgroup file for this user already exists in the specified directory, Microsoft Access replaces it.
Application.CreateNewWorkgroupFile _ Path:="C:\Documents and Settings\Wendy Vasse" _ & "\Application Data\Microsoft\Access", _ Name:="Wendy Vasse", _ Company:="Microsoft", _ Replace:=True