library(SWinTypeLibs)
library(RDCOMClient)
library(RDCOMServer)
library(RDCOMEvents)
app = COMCreate("Word.Application")
lib = LoadTypeLib(app)
interface=generateInterface(lib, c("_Application","_Document","Documents", "Range"), events=FALSE)
writeCode(interface, "WordCode.R")
#source("WordCode.R")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.