File onEvent Method

Here is an example of VB code to request replication on a specific file. It triggers the server to check through the Replication Rules for a matching onEvent replication rule for that requesting user’s Identity and Vault. This example would be run through an Item Action on a file item to call this method. You would run this as an administrator by navigating to Administration>Files, locating the file through a search, and running the action on a file.
’ FileId refers to the file to be replicated, in this case, the File selected when the action is run
Dim FileId As String = Me.getID()
Dim inn As Innovator = Me.getInnovator()
Dim innrep, innresult As Item
innrep = inn.newItem(“File”,"replicate”)
innrep.setId(FileId)
innresult = innrep.apply()