RStudio server and Shiny server

Almost there, so run the app yes, change the code no

Hi, How do I get the name of an uploaded file in shiny? I am using input$file$name in the function cann but it does not work. It works if I send as parameter the name of the file, instead input$file$name. Please see working example

observeEvent(input$value,{
   if(input$value == 'Y'){
     inFile = input$file
     inFileName = inFile$name
     result <- glycoPipe("PARAMS.tsv")
     returnedValue = result$params
     output$box <- renderText({
       paste("Your result is ", returnedValue)
     }
     )
    }
  })

Hi @giuseppa.cefalu, is this a duplicate question? Integrating R code with Shiny app

Yes. Sorry. I was not sure whether I was replying to srisivanicharan or to you.

Cool, no problem. Would you mind reviewing your open posts and marked those for which original questions has been addressed? And then open a single thread for your code question? This will sure help the community know where to offer help, and where others can come for help to find solved questions.

How do I mark that the questions have been addressed?

I describe/have a screen shot here:

1 Like

So make code changes locally, copy it onto the Shiny server and then run the app?

Hey @srisivanicharan, yes, that's it!

Why am I getting srisivanicharan messages?

Oh right, that's because this post was opened by you

@srisivanicharan, would you mind opening a new post if you have more questions about Shiny Server please?

Got it edgararuiz. Thank you.

1 Like

I can find the like symbol and another under the post but I cannot find the solution one.

I have marked all the resolved questions.

Awesome, thank you!

Please feel free to cc me in a your new post for your current Shiny code question if you still need help

How do I cc you? I still have this questions. This is the file upload input

fluidRow(
                   column(width = 10, fileInput("file", "upload the file", accept = ".tsv", placeholder = "No file selected", multiple = FALSE))
                 )
observeEvent(input$value,{
   if(input$value == 'Y'){
     inFile = input$file
     inFileName = inFile$name
     result <- glycoPipe("PARAMS.tsv")
     returnedValue = result$params
     output$box <- renderText({
       paste("Your result is ", returnedValue)
     }
     )
    }
  })

I know the function call works because when I sen the actual file name i get the expected results. It does not work when I use input$file$name

You can just ask the question and type my name at the end of your post:
cc @edgararuiz