Disable script does not work

Ok, so I want to disable my C# script with my javascript code

function Start() {
    GetComponent(movegui).enabled = false;

the code should disable my C# code, the thing is it shows me an error

Assets/Standard Assets/hover Script.js(14,14): BCE0005: Unknown identifier: 'movegui'.

The name of my C# code is movegui so why it still shows me this error and how to fix it?
Thank you for help.

C# and JS can’t see each other during compilation because the compilers are different. You must place the C# script in a folder that will be compiled before the JS script - take a look at Script Compilation (Advanced) in the docs to know which folders are compiled first.

But in this specific case, you can work around this by simply getting the script with the string version of GetComponent:

function Start(){
    (GetComponent("movegui") as MonoBehaviour).enabled = false;

The string GetComponent version searches for the target script by name at runtime, thus the compilation order doesn’t matter.