Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replication activated by Button on Form

Status
Not open for further replies.

GriffG

Programmer
Feb 13, 2005
10
NZ
I am trying to find a way to put a button onto an Access Form and have that activate the replication prosess. how would one do that?
 
This code can be used to create a replica.. You must have the db closed to create a replica.
Code:
Private Sub cmdCreateReplica_Click()
On Error GoTo cmdCreateReplica_Click_Error
   [b] DoCmd.RunCommand acCmdCreateReplica
[/b]Exit_cmdCreateReplica_Click:
    Exit Sub
cmdCreateReplica_Click_Error:
    Select Case Err.Number
    Case 0
    Case 2046 Or 2501
        Resume Next
    Case Else
        MsgBox Err.Number & ": " & Err.Description
    End Select
        Resume Exit_cmdCreateReplica_Click
End Sub

Zameer Abdulla
[sub]Jack of Visual Basic Programming, Master in Dining & Sleeping[/sub]
Visit Me
 
The process of creating the replicas to start with is no problem. I am able to do that from the menu before I lock the Database.

what I am wanting is code to be able to do the syncronisation process from a button on the form.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top