Common
Add DBMoto Functions
Use the DBMoto Function Setup page to add a DBMoto global script function. Users can also write their own function in the replication script that the global script can call in. DBMoto supports Visual Basic and C#.
The following is an example of a global script function:
using System;
using System.Data;
using DBMotoPublic;
using DBMotoScript;
namespace DBRS
{
public class ReplicationScript : IReplicationScript
{
public override void Record_onAfterMapping(DBMotoPublic.IRecord recSource, DBMotoPublic.IRecord recTarget, ref bool AbortRecord)
{
GlobalScript.AddLog("The current record has been inserted", 0);
}
}
}
To add a DBMoto Function in Common:
- Navigate to Configuration > Modules > DBMoto Function Setup in the Navigation pane.
- Enter the name of the function in the FUNCTION NAME text box.
- Enter the global script function in the FUNCTION SCRIPT text area.
- Click Save.
Was this article helpful?
Sorry about that.
Why wasn't this helpful? (check all that apply)
Thanks for your feedback.
Want to tell us more?
Send an email to our authors to leave your feedback.
Great!
Thanks for your feedback.