Loading ...
Sorry, an error occurred while loading the content.

Pagemanagment

Expand Messages
  • Burkhard Stollenwerk
    Hello, How could I built a new page of data at window. Problem is that data is not ready if I ´ll display it. Here is part of code. Burkhard Stollenwerk var
    Message 1 of 1 , Mar 7, 2004
    • 0 Attachment
      Hello,
      How could I built a new page of data at window.
      Problem is that data is not ready if I ´ll display it.
      Here is part of code.

      Burkhard Stollenwerk
      var felder_aktiv="FALSE";
      function felderelemente() // create/update from rowlist in window
      {
      var tabledata=createTableData();
      Table =
      createTable(5,25,635,13,"Parzellen",tabledata,createColumnModel(tabledata))
      Table.action="alert(this.data[this.selectedCol][this.selectedRow])"
      var nextbt=new GeoButton({x:42,y:5,width:25,height:15,
      action:"removeWindowWidget(this.container);next(1,this.Table)",
      value:">>",align:"middle",adjust:"fit", forecolor:"#003399"});
      var prevbt=new GeoButton({x:5,y:5,width:25,height:15,
      action:"removeWindowWidget(this.container);next(-1,this.Table)",
      value:"<<",align:"middle",adjust:"fit", forecolor:"#003399"});
      var str="Seite 1 von 5"
      var txt0 = new GeoLabel({x:568, y:5, width:72, height:14, value:str,
      forecolor:"blue",align:"middle",adjust:"fit"});
      felderwindow.addWidget(Table);
      felderwindow.addWidget(nextbt);
      felderwindow.addWidget(prevbt);
      felderwindow.addWidget(txt0);
      felderwindow.pack();

      }


      function felder()/// first display first datarows until 10 , first page
      {
      felderwindow=new GeoWindow({x:12, y:45, width:1,
      height:1,title:"Parzellenliste"});
      felderwindow.show();
      felderelemente();
      felder_aktiv="TRUE";
      }

      function next(s,t)
      {
      // holen der neuen Reihen
      seite=seite+s*10;
      if (seite<0) seite=0;
      alert(seite+pw+user);
      pw="demo";user="demo";
      str="flachenlis.php?pw="+pw+"&user="+user+"&beginn="+(seite)+"&maxpos=5";
      alert(str)
      getURL(str,callback_get_meta); // Callback and then call felderelemente
      that display new



      }



      function callback_get_meta(urlRequestStatus)
      {
      if ((ver.indexOf("Adobe")!=-1) && (ver.indexOf("6.0")!=-1) )
      {
      metadoc=parseXML(urlRequestStatus.content);
      }
      else
      {
      metadoc=parseXML(urlRequestStatus.content,document);
      }


      // *********************** Mathias FATENE ********************* //
      if(urlRequestStatus.success==false) {
      alert('Fehler bei Verbindung zum Server')
      return 0;
      }
      // *********************** Mathias FATENE ********************* //
      ///////////////////////////////////
      data=printNode(metadoc).split("\n")
      //alert("data = "+data);
      for (child=0; child < data.length; child++) {
      if (child == 0)
      metadoc=''
      else
      metadoc=metadoc+"\n"+data[child];
      }
      metadoc=metadoc+"\n"+'</metadata>'+"\n";

      new_node = parseXML( metadoc, document )
      //alert(new_node+metadoc)
      child=svgdoc.getElementById("overlays")
      child.appendChild(new_node);
      if (felder_aktiv=="TRUE")
      {
      alert(">>"+felder_aktiv);
      felderelemente(); // create new list /page
      }
      }
    Your message has been successfully submitted and would be delivered to recipients shortly.