
var scObj1 = new scrollObject("contentarea1", 625, 220, "up", 6600, 1.1);

scObj1.block[0] = "<div class=content><span style='width:445px;'><strong class=wieh2>Relaunch www.lutzundunglaube.de</strong><br />Für unseren Kunden - das Architekturbüro Lutz + Unglaube in Bonn - haben wir soeben den Internetauftritt relaunched. Der Internetauftritt wurde mit dem Schwerpunkt einer optisch ansprechenderen Präsentation der Rererenzobjekte als auch einer optimierten Suchmaschinenpräsenz überarbeitet. <br /><a href='http://www.lutzundunglaube.de' target='_blank'>&raquo; www.lutzundunglaube.de</a></span><a href='http://www.lutzundunglaube.de' target='_blank'><img src=gif/relaunch.png width=128 height=128 style='border:none;' alt='Architekturbüro Lutz + Unglaube in Bonn' title='Architekturbüro Lutz + Unglaube in Bonn' border=0  /></a></div>";


scObj1.block[1] = "<div class=content><span style='width:445px;'><strong class=wieh2>Dr. Hansen Social Media</strong><br />Nun sind auch wir Social Media 'geworden'.<br /> Besuchen Sie uns doch bei Facebook oder bei XING<br /><a href='https://www.xing.com/companies/dr.hansenedvconsultinggmbh' target='_blank'>&raquo; Dr. Hansen EDV Consulting bei XING</a><br /><a href='http://www.facebook.com/pages/Dr-Hansen-EDV-Consulting-GmbH/159780450701124?v=info&ref=ts' target='_blank'>&raquo; Dr. Hansen EDV Consulting bei Facebook</a></span><img src=gif/socialmedia.png width=128 height=128 style='border:none;' alt='Dr. Hansen EDV Consulting GmbH bei Facebook und XING' title='Dr. Hansen EDV Consulting GmbH bei Facebook und XING' border=0  /></div>";

scObj1.block[2] = "<div class=content><span style='width:445px;'><strong class=wieh2>Neues Fortbildungsportal für Steuerberater</strong><br />Für unseren langjährigen Kunden - die Akademie für Steuerrecht und Wirtschaft des StBV - wurde ein neues Portal erstellt, welches die bisherigen getrennten Fortbildungangebote von  ASW und Steuerberaterverband vereinigt und durch zahlreiche Funktionen ergänzt.<br /><a href='http://www.asw-stbv.de' target='_blank'>&raquo; www.asw-stbv.de</a></span><a href='http://www.asw-stbv.de' target='_blank'><img src=gif/relaunch.png width=128 height=128 style='border:none;' alt='www.asw-stbv.de' title='www.asw-stbv.de' border=0  /></a></div>";

scObj1.block[3] = "<div class=content><span style='width:445px;'><strong class=wieh2>Relaunch www.asi-online.de</strong><br />Für unseren langjährigen Kunden - die A.S.I. Wirtschaftsberatung AG - überarbeiten wir zurzeit die Webpräsenz. Im Zuge der Überarbeitung wird der Internetauftritt dem aktuellen Corporate Design des Unternehmens angepasst.<br /><a href='http://www.asi-online.de' target='_blank'>&raquo; www.asi-online.de</a></span><a href='http://www.asi-online.de' target='_blank'><img src=gif/relaunch.png width=128 height=128 style='border:none;' alt='A.S.I. Wirtschaftsberatung AG' title='A.S.I. Wirtschaftsberatung AG' border=0  /></a></div>";



function scrollObject(main, width, height, direct, pause, speed) {
  var self = this;
  this.main = main;
  this.width = width;
  this.height = height;
  this.direct = direct;
  this.pause = pause;
  this.block = new Array();
  this.offset = (direct == "up" || direct == "down") ? height : width;
  this.speed = Math.max(1.001, Math.min(this.offset, speed));
  this.blockprev = 0;
  this.blockcurr = 1;
  this.motion = false;
  this.mouse = false;
  this.scroll = function() {
    if (!document.getElementById) return false;
    this.main = document.getElementById(this.main);
    while (this.main.firstChild) this.main.removeChild(this.main.firstChild);
    for (var x = 0; x < this.block.length; x++) {
      var table = document.createElement('table');
          table.style.position = "absolute";
          table.style.width = this.width + "px";
          table.style.height = this.height + "px";
          table.style.overflow = "hidden";
          table.cellPadding = table.cellSpacing = table.border = "0";
          table.style.left = table.style.top = "0px";
        if (x) {
          switch (this.direct) {
            case "up": table.style.top = this.height + "px"; break;
            case "down": table.style.top = -this.height + "px"; break;
            case "left": table.style.left = this.width + "px"; break;
            case "right": table.style.left = -this.width + "px"; break;
          }
        }
        var tbody = document.createElement('tbody');
          var tr = document.createElement('tr');
            var td = document.createElement('td');
                td.innerHTML = this.block[x];
              tr.appendChild(td);
            tbody.appendChild(tr);
          table.appendChild(tbody);
      this.main.appendChild(this.block[x] = table);
    }
    this.main.style.position = "relative";
    this.main.style.width = this.width + "px";
    this.main.style.height = this.height + "px";
    this.main.style.overflow = "hidden";
    if (this.block.length > 1) {
      this.main.onmouseover = function() { self.mouse = true; }
      this.main.onmouseout = function() { self.mouse = false; }
      setInterval(function() { self.scrollLoop(); }, this.pause);
    }
  }
  this.scrollLoop = function() {
    if (!this.motion && this.mouse) return false;
    if (!(this.offset = Math.floor(this.offset / this.speed))) {
      var blocknext = (this.blockcurr + 1 >= this.block.length) ? 0 : this.blockcurr + 1;
    } else this.motion = true;
    switch (this.direct) {
      case "up":
        this.block[this.blockcurr].style.top = this.offset + "px";
        this.block[this.blockprev].style.top = (this.offset - this.height) + "px";
        if (!this.offset) this.block[blocknext].style.top = this.height + "px";
        break;
      case "down":
        this.block[this.blockcurr].style.top = -this.offset + "px";
        this.block[this.blockprev].style.top = (this.height - this.offset) + "px";
        if (!this.offset) this.block[blocknext].style.top = -this.height + "px";
        break;
      case "left":
        this.block[this.blockcurr].style.left = this.offset + "px";
        this.block[this.blockprev].style.left = (this.offset - this.width) + "px";
        if (!this.offset) this.block[blocknext].style.left = this.width + "px";
        break;
      case "right":
        this.block[this.blockcurr].style.left = -this.offset + "px";
        this.block[this.blockprev].style.left = (this.width - this.offset) + "px";
        if (!this.offset) this.block[blocknext].style.left = -this.width + "px";
        break;
    }
    if (!this.offset) {
      this.motion = false;
      this.blockprev = this.blockcurr;
      this.blockcurr = blocknext;
      this.offset = (this.direct == "up" || this.direct == "down") ? this.height : this.width;
    } else setTimeout(function() { self.scrollLoop(); }, 30);
  }
}
