function Scroll_(Size, Width, Height, Speed, ScrollSize, Element)
{
    this.ScrollDivOuter = null;
    this.ScrollDivInner = null;
    this.ScrollWidth = Width;
    this.ScrollHeight = Height;
    this.ScrollSpeed = Speed;
    this.Scrolling = false;
    this.ScrollPixel = ScrollSize;
    this.TimerStart = false;
    this.TimerStop = false;
    this.OffsetSize = Size;

    this.Ajax = new XMLHTTPObject_();


    this.Clear = function()
    {
        General.DOMInsertHTML(this.ScrollDivInner);
    }

    this.DisplayContent = function(Data)
    {
        this.ScrollDivInner.style.top = "0px";
        this.ScrollDivInner.style.left = "0px";
        General.DOMInsertHTML(this.ScrollDivInner, Data);
        Form.Initialize();
    }

    this.ChangeContent = function(URL, Variable)
    {
        this.Ajax.CallBack(this, this.DisplayContent);
        this.Ajax.Request("POST", URL, Variable);
    }

    this.MouseOver = function(Object, Direction)
    {
        Object.style.cursor = 'pointer';
        this.Scrolling = true;
        this.ScrollDirection = Direction;
        this.TimerStart = false;
        if(this.TimerStart == false)
        {
            this.intervalTimer = setInterval(this.ScrollTimer.bind(this), this.ScrollSpeed);

            this.TimerStart = true;
            this.TimerStop = false;
        }
    }

    this.MouseOut = function(Object)
    {
        this.Scrolling = false;
        this.ScrollDirection = null;
        this.TimerStop = false;

        if(this.TimerStop == false)
        {
            clearInterval(this.intervalTimer);

            this.TimerStop = true;
            this.TimerStart = false;
        }
    }

    this.ScrollTimer = function()
    {
        if (this.Scrolling)
        {
            switch(this.ScrollDirection.toLowerCase())
            {
                case "up":
                    if (parseFloat(this.ScrollDivInner.style.top)<0)
                            this.ScrollDivInner.style.top = (parseFloat(this.ScrollDivInner.style.top) + this.ScrollPixel) + "px";
                    break;

                case "down":
                    if (parseFloat(this.ScrollDivInner.style.top)>((this.ScrollDivInner.offsetHeight-this.ScrollHeight)*-1))
                            this.ScrollDivInner.style.top = (parseFloat(this.ScrollDivInner.style.top) - this.ScrollPixel) + "px";
                    break;

                case "left":
                    if (parseFloat(this.ScrollDivInner.style.left)<0)
                            this.ScrollDivInner.style.left = (parseFloat(this.ScrollDivInner.style.left) + this.ScrollPixel) + "px";
                    break;

                case "right":
                    if (parseFloat(this.ScrollDivInner.style.left)>((this.ScrollDivInner.offsetWidth-this.ScrollWidth)*-1))
                            this.ScrollDivInner.style.left = (parseFloat(this.ScrollDivInner.style.left) - this.ScrollPixel) + "px";
                    break;
            }
        }
    }

    if (typeof(Element)=="string")
            Element = document.getElementById(Element);

    this.ScrollDivOuter = document.createElement("div");
    this.ScrollDivOuter.style.position = "relative";
    this.ScrollDivOuter.style.top = "0px";
    this.ScrollDivOuter.style.left = "0px";
    this.ScrollDivOuter.style.overflow = "hidden";
    this.ScrollDivOuter.style.width = this.ScrollWidth+"px";
    this.ScrollDivOuter.style.height = this.ScrollHeight+"px";

    this.ScrollDivInner = document.createElement("div");
    this.ScrollDivInner.style.position = "relative";
    this.ScrollDivInner.style.top = "0px";
    this.ScrollDivInner.style.left = "0px";
    this.ScrollDivInner.style.width = this.OffsetSize+"px";

    this.ScrollDivOuter.appendChild(this.ScrollDivInner);

    Element.parentNode.insertBefore(this.ScrollDivOuter, Element);
}