How do I restore R script icon? - rscript

I used to save R script data with "R" icon on it. The file extension is okey with ".R" file type. But the icon shows RStudio file extension. I tried uninstalling R and RStudio, restore PC...., still the "R script" icon not yet restored. Very much thankful if anyone help me on how to to restore "R script" icon.

Related

How to correct VS Code terminal pointing to wrong folder C:\Windows\System32\WindowsPowerShell\v1.0?

I try to open a React project path in terminal window using VS Code's Open in Integrated Terminal (Ctrl+Shift+`), but it sets C:\Windows\System32\WindowsPowerShell\v1.0 as current directory and not the project directory.
It doesn't behave like that for other projects (folders & paths).
This happened after I moved the files to another folder on my PC.
Screen shot of VS Code context menu with menu item Open in Integrated Terminal and the TERMINAL window with Windows PowerShell output and the path set as current directory.
this is return to special characters in file name.
characters like [ , ] made this error on VS code. git bash and CMD run well with them but vs code not.im not certain this is a bug or not

Setting path on VS command prompt

I'm new to coding. I have Visual Studio 2019 and am doing tutorials to learn.
The command prompt is: C:\Program Files (x86)\Microsoft Visual Studio\2019\community> . When I try to go to a file, my entire community folder appears. How can I set the path to something else that allows me to go to the file I want? Example: mkdir projects>cd projects>mkdir helloworld>cd helloworld>code .
I tried a couple times with no change.
How are you starting your VS 2019? After you install it, you should have a item "Visual Studio 2019" with a purple icon next to it. It is below where you have the developer prompt. After you have made your directory, use that to start VS.
Click on "Create a new project". On the next screen, you specify you want to create a C/C++ console application or whatever. On the following screen, you can specify whatever directory where want your solution to be.
If this answers your question, click the check mark to the left of this answer to indicate the problem has been solved.

ONLYOFFICE and mime-types assosiasions

I`m using Elementary Os Loki and wanted to use ONLYOFFICE.
I tried installing the last deb file from official site and tried to use the repo(no change). The problem is that when the package installs it doesn`t register itself to allow opening the file from filemanager or terminal(desktopeditors -f example.doc or smth).
I found whole dir in the official repo where I think all logic is handled.
(https://github.com/ONLYOFFICE/desktop-apps/tree/master/win-linux/package/linux/qt-installer/packages/onlyoffice/data)
I also tried to fix by changing file in /usr/share/applications - defaults.list and desktopeditors.desktop.
Please fix this or give a nice explaination if it a feature.
The only way to open a file is to use internal file chooser dialog or to drag&drop a file on the window.
It is a bug in onlyoffice-desktopeditors. We will fix it soon. You can set file associations: open context menu of the file, choose "open with" -> "other applications". Then find 'desktopeditors' in recommended applications, select this and press 'Set as default' button.
After this you will be able to open files from file manager in ONLYOFFICE.

Post-Build Event Fails to Run Batch File

I recently started adding Post-Build events to my projects and today I came across an annoying issue.
Post-build event command line:
"$(ProjectDir)PostBuildRelease.bat"
PostBuildRelease.bat - 1
CMD
SET parameter=%1
CD %1
The above errors with message:
'´╗┐CMD' is not recognized as an internal or external command,
operable program or batch file.
"Saved parameter "
Which is strange, because I definitely have another project where the first line reads CMD and it works perfectly.
Setting the first line to SET parameter=%1 also complains that SET is not a recognised command.
PostBuildRelease.bat - 2
Trying the same but with an empty file gives this error (build fails):
The command "C:\Users\name\ITSelfHelp\ITHelp\PostBuildRelease.bat" exited with code 1.
PostBuildRelease - 3
Entering the CMD code directly into the Post-Build Event command line field results in a successful post-build event, but this is not ideal for me and seems strange as I can run from an external .bat in other projects.
Can anyone explain this behaviour, or let me know how I can debug this?
It turns out the text editor in Visual Studio was encoding my batch script.
To recreate this:
Right-click the solution
Add file
Text file
Rename file.bat
Write the script in Visual Studio
Build
Check the output window for the error
To resolve:
Delete the file created in Visual Studio
Created a new .bat file in the same location using Windows Explorer
Open the file with Notepad++ and paste in the script
Save and build
I also noticed that syntax highlighting was not being applying in the file created by Visual Studio, which is a bit of a giveaway along with the ´╗┐ in front of the errors.

How download exe files with ChromeDriver?

I try to download exe files via ChromeDriver. But I see the following message: "This type of files can harm your computer..."
How I can avoid this message?
I don't think that we can switch off those messages in Chrome.
But i have a workaround.
1) chrome://settings/ --> Downloads --> Select the "Ask where to save each file before downloading" check box. Then every time before downloading a file chrome will ask you where to save the file & the default location is "Downloads" folder.
2) Write an AutoIt script just to press ENTER (As the focus is already on the popup).
Send("{ENTER}")
3) Once you click on the Download link, Run the above AutoIt Script using below command:
Runtime.getRuntime().exec("Path of the AutoIt executable");
It's fine to download files. It will shows such error for .js, .exe, .dll, excel macro files etc.
Things need to remember is when you try to install the software with any installer when you double click the exe file it will show you publisher name. If publisher is unknown it may possible that exe file is altered.
Most of the trusted software publishers use Code Signing Certificate to validate their software package. This way software shows their company name as a publisher, and assure that the software is not altered.

Resources