Freigeben über


Database.ReplicaID-Eigenschaft (DAO)

Gilt für: Access 2013, Office 2013

Gibt einen 16-Byte-Wert zurück, der ein Replikat einer Datenbank eindeutig kennzeichnet (nur Microsoft Access-Arbeitsbereiche).

Syntax

Ausdruck . Replicaid

Ausdruck Eine Variable, die ein Database -Objekt darstellt.

Hinweise

Der Rückgabewert ist ein GUID-Wert, der das Replikat oder den Designmaster eindeutig kennzeichnet.

Die Microsoft Access-Datenbank-Engine generiert diesen Wert automatisch, wenn Sie ein neues Replikat erstellen.

Die ReplicaID-Eigenschaft jedes Replikats (und der Designmaster) ist in der MSysReplicas-Systemtabelle gespeichert.

Beispiel

This example makes a replica from the Design Master of Northwind.mdb, and then returns the replica's ReplicaID, which is automatically created by the Microsoft Access database engine. (If you have not yet created a Design Master of Northwind, refer to the Replicable property, or change the name of the database in the code to an existing Design Master.)

Sub MakeReplicaReplicaIDX() 
 
 Dim dbsNorthwind As Database 
 Dim prpReplicaID As Property 
 Dim dbsReplica As Database 
 
 Set dbsNorthwind = OpenDatabase("Northwind.mdb") 
 
 ' Makes a new replica. 
 dbsNorthwind.MakeReplica "Nwreplica2.mdb", _ 
 "second replica" 
 dbsNorthwind.Close 
 
 ' Opens the new replica to read its ReplicaID. 
 Set dbsReplica = OpenDatabase("Nwreplica2.mdb") 
 
 Debug.Print dbsReplica.ReplicaID 
 dbsReplica.Close 
 
End Sub