How to access hinge joint variables

Hi everyone ive got a problem with HingeJoints... I want to activate the hinge joint motor via script but i dont get access to the variables. The script is attached directly to the object( in this case its a door). This is the error Log: /HoH_DoorOpener.cs(51,24): error CS1612: Cannot modify the return value of `UnityEngine.HingeJoint.motor' because it is not a variable

I dont know what to do to access theese variables. If enyone could help me i would be very happy :)

using UnityEngine;
using System.Collections;

public class HoH_DoorOpener : MonoBehaviour
{

    public int sizeX = 50;
    public int sizeY = 50;
    public float iAppearDistance = 3;
    public Transform FPSPlayer;
    public Texture2D HandSymbol;

    Vector3 mousePos = new Vector3(0, 0, 0);
    float fDistance = 0;
    bool doWindow = false;

    void Update()
    {

        fDistance = Vector3.Distance(transform.position, FPSPlayer.position);
        print(fDistance);

        if (fDistance <= iAppearDistance)
        {
            doWindow = true;
        }
        else 
        {
            doWindow = false;
        }

        if (Input.GetMouseButton(0) && doWindow)
        {

            //Here is the problem, where i cant access the variables...
            hingeJoint.motor.force = 10;
            hingeJoint.motor.targetVelocity = 10;
            hingeJoint.motor.freeSpin = true;

            print("Opening Door...");
        }

        if (Input.GetMouseButton(1) && doWindow)
        {
            //similar problems at this point ^^

            print("Closing Door...");
        }
    }

    void OnGUI()
    {

        if (doWindow)
        {
            GUI.Label(new Rect(Screen.width / 2, Screen.height / 2, sizeX, sizeY),    
            HandSymbol);
        }   
    }
}

First off, make sure that this script is attached to the same Game Object that has the Hinge Joint. If that doesn't work, try this code:

JointMotor m = new JointMotor();
m.force = ...;
m.targetVelocity = ...;
m.freeSpin = ...;
hingeJoint.motor = m;

maybe the game engine can’t convert the numbers, try like 10f… Bad english, sorry.

Assigning the value at runtime, Dont affect “Hingejoint” Motor…???