upload error for rpub

I tried to publish my HTML after knit to rpub. But I got this error:

upload error occured

Error in loadNamespace(x) : there is no package called 'rsconnect'
Calls: loadNamespace -> withRestarts -> withOneRestart -> doWithOneRestart
Execution halted

I am using the latest version of Rstudio now. Can anyone help with this issue?

Thank you very much!

Best
Eric

The message said that you need install library rsconnect.
Make this and run.

install.packages("rsconnect")

Thanks for the help. I did it and restarted my Rstudio. But I still got the same error message.

If you get exactly the same result then most likely the installation process has failed, please post the complete console output you get when you try to install it so we can take a look at it.