# NOT RUN {
if(interactive()) {
library(shiny)
library(excelR)
shinyApp(
ui = fluidPage(excelOutput("table", height = 175),
actionButton('comment', 'Set Comments to cell A1')),
server = function(input, output, session) {
output$table <- renderExcel(excelTable(data = head(iris)))
observeEvent(input$comment,{
setComments("table", "A1", "This is a comment")
})
}
)
}
# }
Run the code above in your browser using DataLab