Question

Error: Length is null or not an object. I don't get this...????

Asked by: jensjakobsen

Hi All

I've created a webpage with DW MX 2004. Nothing handcoded just DW created code.

The link to the error is here: http://www.dragonswim.dk/join.asp

The error code is:

Line 96
Char: 22
Error: 'Length' is null or not an object
Code: 0
URL: http://www.dragonswim.dk/join.asp

The whole code is here:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<!--#include file="[connection string file here]" -->
<!--#include file="[another connection string file here]" -->
<%
' *** Edit Operations: declare variables

Dim MM_editAction
Dim MM_abortEdit
Dim MM_editQuery
Dim MM_editCmd

Dim MM_editConnection
Dim MM_editTable
Dim MM_editRedirectUrl
Dim MM_editColumn
Dim MM_recordId

Dim MM_fieldsStr
Dim MM_columnsStr
Dim MM_fields
Dim MM_columns
Dim MM_typeArray
Dim MM_formVal
Dim MM_delim
Dim MM_altVal
Dim MM_emptyVal
Dim MM_i

MM_editAction = CStr(Request.ServerVariables("SCRIPT_NAME"))
If (Request.QueryString <> "") Then
  MM_editAction = MM_editAction & "?" & Server.HTMLEncode(Request.QueryString)
End If

' boolean to abort record edit
MM_abortEdit = false

' query string to execute
MM_editQuery = ""
%>
<%
' *** Insert Record: set variables

If (CStr(Request("MM_insert")) = "form1") Then

  MM_editConnection = MM_Conn_STRING
  MM_editTable = "profil"
  MM_editRedirectUrl = "thankyou.asp"
  MM_fieldsStr  = "fornavn|value|mellemnavn|value|efternavn|value|birthdate|value|adresse|value|postnummer|value|byen|value|telefon|value|public_phone|value|mobil|value|public_mobile|value|mail|value|education|value|out|value|coach|value|helpcoach|value|activecoach|value|activehelpcoach|value|swimmer|value|activeswimmer|value|hold|value|team_leader|value|official|value|tidtager|value|bestyrelse|value|venteliste|value|public_mail|value"
  MM_columnsStr = "fornavn|',none,''|mellemnavn|',none,''|efternavn|',none,''|birthdate|',none,NULL|adresse|',none,''|postnummer|',none,''|byen|',none,''|telefon|',none,''|public_phone|none,none,NULL|mobil|',none,''|public_mobile|none,none,NULL|mail|',none,''|education|',none,''|out|none,none,NULL|coach|none,none,NULL|helpcoach|none,none,NULL|activecoach|none,none,NULL|activehelpcoach|none,none,NULL|swimmer|none,none,NULL|activeswimmer|none,none,NULL|hold|none,none,NULL|team_leader|none,none,NULL|official|none,none,NULL|tidtager|none,none,NULL|bestyrelse|none,none,NULL|venteliste|none,none,NULL|public_mail|none,none,NULL"

  ' create the MM_fields and MM_columns arrays
  MM_fields = Split(MM_fieldsStr, "|")
  MM_columns = Split(MM_columnsStr, "|")
 
  ' set the form values
  For MM_i = LBound(MM_fields) To UBound(MM_fields) Step 2
    MM_fields(MM_i+1) = CStr(Request.Form(MM_fields(MM_i)))
  Next

  ' append the query string to the redirect URL
  If (MM_editRedirectUrl <> "" And Request.QueryString <> "") Then
    If (InStr(1, MM_editRedirectUrl, "?", vbTextCompare) = 0 And Request.QueryString <> "") Then
      MM_editRedirectUrl = MM_editRedirectUrl & "?" & Request.QueryString
    Else
      MM_editRedirectUrl = MM_editRedirectUrl & "&" & Request.QueryString
    End If
  End If

End If
%>
<%
' *** Insert Record: construct a sql insert statement and execute it

Dim MM_tableValues
Dim MM_dbValues

If (CStr(Request("MM_insert")) <> "") Then

  ' create the sql insert statement
  MM_tableValues = ""
  MM_dbValues = ""
  For MM_i = LBound(MM_fields) To UBound(MM_fields) Step 2
    MM_formVal = MM_fields(MM_i+1)
    MM_typeArray = Split(MM_columns(MM_i+1),",")
    MM_delim = MM_typeArray(0)
    If (MM_delim = "none") Then MM_delim = ""
    MM_altVal = MM_typeArray(1)
    If (MM_altVal = "none") Then MM_altVal = ""
    MM_emptyVal = MM_typeArray(2)
    If (MM_emptyVal = "none") Then MM_emptyVal = ""
    If (MM_formVal = "") Then
      MM_formVal = MM_emptyVal
    Else
      If (MM_altVal <> "") Then
        MM_formVal = MM_altVal
      ElseIf (MM_delim = "'") Then  ' escape quotes
        MM_formVal = "'" & Replace(MM_formVal,"'","''") & "'"
      Else
        MM_formVal = MM_delim + MM_formVal + MM_delim
      End If
    End If
    If (MM_i <> LBound(MM_fields)) Then
      MM_tableValues = MM_tableValues & ","
      MM_dbValues = MM_dbValues & ","
    End If
    MM_tableValues = MM_tableValues & MM_columns(MM_i)
    MM_dbValues = MM_dbValues & MM_formVal
  Next
  MM_editQuery = "insert into " & MM_editTable & " (" & MM_tableValues & ") values (" & MM_dbValues & ")"

  If (Not MM_abortEdit) Then
    ' execute the insert
    Set MM_editCmd = Server.CreateObject("ADODB.Command")
    MM_editCmd.ActiveConnection = MM_editConnection
    MM_editCmd.CommandText = MM_editQuery
    MM_editCmd.Execute
    MM_editCmd.ActiveConnection.Close

    If (MM_editRedirectUrl <> "") Then
      Response.Redirect(MM_editRedirectUrl)
    End If
  End If

End If
%>
<%
Dim RSTid
Dim RSTid_numRows

Set RSTid = Server.CreateObject("ADODB.Recordset")
RSTid.ActiveConnection = MM_ConnNews_STRING
RSTid.Source = "SELECT timestamp  FROM tblMenu  WHERE category = 'coach'  ORDER BY ID desc"
RSTid.CursorType = 0
RSTid.CursorLocation = 2
RSTid.LockType = 1
RSTid.Open()

RSTid_numRows = 0
%><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>
<!--#include file="title.asp"-->
</title>
<link href="css/default7.css" rel="stylesheet" type="text/css">
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
/* BEGIN Advanced HTML Editor */
var BaseURL = "../../Dragonswimdk/www/";
/* END Advanced HTML Editor */
//-->

</script>
<SCRIPT TYPE="text/javascript">
<!--
var submitRolls = new Object();

function submitroll(src, oversrc, name)
{
this.src=src;
this.oversrc=oversrc;
this.name=name;
this.alt="Submit Query";
this.write=submitroll_write;
}

function submitroll_write()
{
var thisform = 'document.forms[' + (document.forms.length - 1) + ']';
submitRolls[this.name] = new Object();
submitRolls[this.name].over = new Image();
submitRolls[this.name].over.src = this.oversrc;
submitRolls[this.name].out = new Image();
submitRolls[this.name].out.src = this.src;

document.write
      (
      '<A onMouseOver="if (document.images)document.images[\'' + this.name + "'].src=submitRolls['" + this.name + '\'].over.src"' +
      ' onMouseOut="if (document.images)document.images[\'' + this.name + "'].src=submitRolls['" + this.name + '\'].out.src"' +
      ' HREF="javascript:'
      );

if (this.sendfield)
      {
      if (! this.sendvalue)
            this.sendvalue = 1;
      document.write(thisform, ".elements['", this.sendfield, "'].value='", this.sendvalue, "';");
      }

document.write(thisform + '.submit();void(0);"');
if (this.msg)document.write(' onClick="return confirm(\'' , this.msg, '\')"');
document.write('>');

document.write('<IMG SRC="' + this.src + '" ALT="' + this.alt + '" BORDER=0 NAME="' + this.name + '"');
if (this.height)document.write(' HEIGHT=' + this.height);
if (this.width)document.write(' WIDTH='  + this.width);
if (this.otheratts)document.write(' ' + this.otheratts);
document.write('></A>');
if (this.sendfield)
      {
      document.write('<INPUT TYPE=HIDDEN NAME="' + this.sendfield + '">');
      document.forms[document.forms.length - 1].elements[this.sendfield].value='';
      }
}

function altRowColors(){ //v2.0
  var args = arguments, obj, color0, color1, rowList;
  for(var a = 0; a < args.length; a+=3){
    obj = args[a+0]; color0 = args[a+1]; color1 = args[a+2];
    obj = (isNaN(obj)) ? document.getElementById(obj) : document.getElementsByTagName("TABLE")[obj];
    if(obj) rowList = obj.getElementsByTagName("TR");
      for(var i = 0; i < rowList.length; i++) rowList[i].style.backgroundColor = eval('color'+(i % 2));
  }
}

function YY_checkform() { //v4.71
//copyright (c)1998,2002 Yaromat.com
  var a=YY_checkform.arguments,oo=true,v='',s='',err=false,r,o,at,o1,t,i,j,ma,rx,cd,cm,cy,dte,at;
  for (i=1; i<a.length;i=i+4){
    if (a[i+1].charAt(0)=='#'){r=true; a[i+1]=a[i+1].substring(1);}else{r=false}
    o=MM_findObj(a[i].replace(/\[\d+\]/ig,""));
    o1=MM_findObj(a[i+1].replace(/\[\d+\]/ig,""));
    v=o.value;t=a[i+2];
    if (o.type=='text'||o.type=='password'||o.type=='hidden'){
      if (r&&v.length==0){err=true}
      if (v.length>0)
      if (t==1){ //fromto
        ma=a[i+1].split('_');if(isNaN(v)||v<ma[0]/1||v > ma[1]/1){err=true}
      } else if (t==2){
        rx=new RegExp("^[\\w\.=-]+@[\\w\\.-]+\\.[a-zA-Z]{2,4}$");if(!rx.test(v))err=true;
      } else if (t==3){ // date
        ma=a[i+1].split("#");at=v.match(ma[0]);
        if(at){
          cd=(at[ma[1]])?at[ma[1]]:1;cm=at[ma[2]]-1;cy=at[ma[3]];
          dte=new Date(cy,cm,cd);
          if(dte.getFullYear()!=cy||dte.getDate()!=cd||dte.getMonth()!=cm){err=true};
        }else{err=true}
      } else if (t==4){ // time
        ma=a[i+1].split("#");at=v.match(ma[0]);if(!at){err=true}
      } else if (t==5){ // check this 2
            if(o1.length)o1=o1[a[i+1].replace(/(.*\[)|(\].*)/ig,"")];
            if(!o1.checked){err=true}
      } else if (t==6){ // the same
            if(v!=MM_findObj(a[i+1]).value){err=true}
      }
    } else
    if (!o.type&&o.length>0&&o[0].type=='radio'){
          at = a[i].match(/(.*)\[(\d+)\].*/i);
          o2=(o.length>1)?o[at[2]]:o;
      if (t==1&&o2&&o2.checked&&o1&&o1.value.length/1==0){err=true}
      if (t==2){
        oo=false;
        for(j=0;j<o.length;j++){oo=oo||o[j].checked}
        if(!oo){s+='* '+a[i+3]+'\n'}
      }
    } else if (o.type=='checkbox'){
      if((t==1&&o.checked==false)||(t==2&&o.checked&&o1&&o1.value.length/1==0)){err=true}
    } else if (o.type=='select-one'||o.type=='select-multiple'){
      if(t==1&&o.selectedIndex/1==0){err=true}
    }else if (o.type=='textarea'){
      if(v.length<a[i+1]){err=true}
    }
    if (err){s+='* '+a[i+3]+'\n'; err=false}
  }
  if (s!=''){alert('FØLGENDE FELTER MANGLER AT BLIVE UDFYLDT:\t\t\t\t\t\n\n'+s)}
  document.MM_returnValue = (s=='');
}
//-->
</SCRIPT>
<style type="text/css">
<!--

/* BEGIN Advanced HTML Editor */
.dmx_btn     { width: 22px; height: 22px; border: 1px solid #ECE9D8; margin: 0; padding: 0; background-color: #ECE9D8; }
.dmx_btnOver { width: 22px; height: 22px; border: 1px outset; margin: 0; padding: 0; background-color: #FCF9E8; }
.dmx_btnDown { width: 22px; height: 22px; border: 1px inset; margin: 0; padding: 0; background-color: #FCF9E8; }
.dmx_btnNA   { width: 22px; height: 22px; border: 1px solid #ECE9D8; margin: 0; padding: 0; -moz-opacity:0.25; opacity:0.25; filter: alpha(opacity=25);}
.dmx_menuBar { background-color: #ECE9D8; }
.style1 {
      color: #FF0000;
      font-weight: bold;
      font-size: 16px;
}
/* END Advanced HTML Editor */
-->
</style>
<script language="JavaScript" src="../../Dragonswimdk/www/ScriptLibrary/AdvHTMLLang.js"></script>
<script language="JavaScript" src="../../Dragonswimdk/www/ScriptLibrary/AdvHTMLEdit.js"></script>
<body class="new_no_body_margin" onLoad="MM_preloadImages('images/newsite/hjem_b.jpg','images/newsite/nyheder_b.jpg','images/newsite/kalender_b.jpg','images/newsite/fakta_b.jpg','images/newsite/kontakt_b.jpg');altRowColors('data','#f0f0f0','#ffffff')">
      <div class="global">
            <div class="global_main">
                  <div id="top"></div>
                  <div id="top_nav">
                  <form action="soegning.asp" name="Search" method="post">
                  <div class="search_field"><input name="search" type="text" size="20"></div>
                                    <div class="search_button">
                                          <SCRIPT TYPE="text/javascript">
                                          <!--
                                          var sr = new submitroll("submit.out.jpg","submit.over.jpg","mysubmit");
                                          sr.write();
                                          //-->
                                          </SCRIPT>                                    
                                    </div>
                  </form>
                  </div>
                  <div id="toc_top"></div>
                  <div id="toc_content">
                        <div class="toc_nav_top"><a href="default.asp" target="_self" onMouseOver="MM_swapImage('hjem','','images/newsite/hjem_b.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="images/newsite/hjem_a.jpg" alt="HJEM - startside for hele hjemmesiden" name="hjem" width="140" height="40" border="0"></a></div>
                        <div class="toc_nav_top"><a href="news.asp" target="_self" onMouseOver="MM_swapImage('nyheder','','images/newsite/nyheder_b.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="images/newsite/nyheder_a.jpg" alt="Nyheder - lampen blinker hvis nyheder er mindre end 3 dage gamle" name="nyheder" width="140" height="40" border="0"></a></div>  
                        <div class="toc_nav_top"><a href="calendar.asp" target="_self" onMouseOver="MM_swapImage('kalender','','images/newsite/kalender_b.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="images/newsite/kalender_a.jpg" alt="Kalender" name="kalender" width="140" height="40" border="0"></a></div>  
                        <div class="toc_nav_top"><a href="facts.asp" target="_self" onMouseOver="MM_swapImage('fakta','','images/newsite/fakta_b.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="images/newsite/fakta_a.jpg" alt="Oplysninger om svømmeklubben" name="fakta" width="140" height="40" border="0"></a></div>  
                        <div class="toc_nav_top"><a href="contact.asp" target="_self" onMouseOver="MM_swapImage('kontakt','','images/newsite/kontakt_b.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="images/newsite/kontakt_a.jpg" alt="Kontakt klubben" name="kontakt" width="140" height="40" border="0"></a></div>
                  </div>
                  <div id="toc_bottom"></div>
                  <div id="toc_below_bottom">
<!--#include file="subtoc.asp"-->
                  </div>
                  
                  <!--#Her starter nyheden-->
                  <div class="newsitem">
                    <form name="form1" method="POST" action="<%=MM_editAction%>">
                      <table width="510" border="0" cellpadding="0" cellspacing="0" class="news_content">
                  <tr>
                    <td><p class="search_header">Tilmelding til venteliste </p>
                    <p>BEM&AElig;RK - der kan ikke foretages &aelig;ndringer til tidligere afsendte tilmelding til venteliste - disse slettes automatisk hvis man alligevel tilmelder sit barn 2 gange.</p>
                    <p>Istedet skal man rette henvendelse til kontoret for at &aelig;ndre i tilmeldingen - kontakt kontoret herfor</p>
                    <p>Felter markeret med <span class="style1">*</span> SKAL udfyldes. </p>
                    <p>&nbsp;</p></td>
                  </tr>
                  <tr>
                    <td><table width="510" border="0" cellspacing="0" cellpadding="0">
                        <tr>
                          <td width="150">Fornavn <span class="style1">*</span> </td>
                          <td><span class="bggrey">
                            <input name="fornavn" type="text" id="fornavn" size="50">
                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">Mellemnavn(e)</td>
                          <td><span class="bggrey">
                            <input name="mellemnavn" type="text" id="mellemnavn" size="50">
                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">Efternavn <span class="style1">*</span></td>
                          <td><span class="bggrey">
                            <input name="efternavn" type="text" id="efternavn" size="50">
                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">F&oslash;dselsdato <span class="style1">*</span></td>
                          <td><span class="bggrey">
                            <input name="birthdate" type="text" id="birthdate" size="16">
(SKAL v&aelig;re i dd-mm-&aring;&aring;&aring;&aring; format)                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">Adresse <span class="style1">*</span></td>
                          <td><span class="bggrey">
                            <input name="adresse" type="text" id="adresse" size="50">
                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">Postnr. <span class="style1">*</span></td>
                          <td><span class="bggrey">
                            <input name="postnummer" type="text" id="postnummer" size="10">
                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">By <span class="style1">*</span></td>
                          <td><span class="bggrey">
                            <input name="byen" type="text" id="byen" size="50">
                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">Telefon (fastnet) <span class="style1">*</span></td>
                          <td><span class="bggrey">
                            <input name="telefon" type="text" id="telefon" size="20">
                            <input name="public_phone" type="hidden" id="public_phone" value="1">
</span></td>
                        </tr>
                        <tr>
                          <td width="150">Mobiltelefon</td>
                          <td><span class="bggrey">
                            <input name="mobil" type="text" id="mobil" size="20">
                            <input name="public_mobile" type="hidden" id="public_mobile" value="1">
</span></td>
                        </tr>
                        <tr>
                          <td width="150">Mail</td>
                          <td><span class="bggrey">
                            <input name="mail" type="text" id="mail" size="50">
                          </span></td>
                        </tr>
                        <tr>
                          <td width="150">Evner/Bem&aelig;rkninger</td>
                          <td>&nbsp;</td>
                        </tr>
                    </table>
                                                            <textarea dmxedit="true" id="education" name="education" style="width:500px;height:300px;" toolbar="T:BIU;J:LCRF;O:LUOI;X:LIWM" config="mw:100;mh:140;upload:asp;resize:true"></textarea>
                              <input name="Submit" type="submit" onClick="YY_checkform('form1','fornavn','#q','0','Feltet FORNAVN m&aring; ikke v&aelig;re tomt','efternavn','#q','0','Feltet EFTERNAVN m&aring; ikke v&aelig;re tomt','birthdate','#^\([0-9][0-9]\)\\-\([0-9][0-9]\)\\-\([0-9]{4}\)$#1#2#3','3','Feltet F&Oslash;DSELSDATO m&aring; ikke v&aelig;re tomt - eller det er ikke udfyldt korrekt \(DD-MM-&Aring;&Aring;&Aring;&Aring;\)','adresse','#q','0','Feltet ADRESSE m&aring; ikke v&aelig;re tomt','postnummer','#q','0','Feltet POSTNUMMER m&aring; ikke v&aelig;re tomt','byen','#q','0','Feltet BY m&aring; ikke v&aelig;re tomt','telefon','#q','0','Feltet TELEFON m&aring; ikke v&aelig;re tomt','mail','S','2','Feltet MAIL er ikke udfyldt korrekt');return document.MM_returnValue" value="Indsend oplysninger">
                              <input type="submit" name="Submit" value="Annull&eacute;r al indtastning">
                              <span class="bggrey">
                              <input name="out" type="hidden" id="out" value="0">
                    <input name="coach" type="hidden" id="coach" value="0">
                    <input name="helpcoach" type="hidden" id="helpcoach" value="0">
                    <input name="activecoach" type="hidden" id="activecoach" value="0">
                    <input name="activehelpcoach" type="hidden" id="activehelpcoach" value="0">
                    <input name="swimmer" type="hidden" id="swimmer" value="1">
                    <input name="activeswimmer" type="hidden" id="activeswimmer" value="0">
                    <input name="hold" type="hidden" id="hold" value="0">
                    <input name="team_leader" type="hidden" id="team_leader" value="0">
                    <input name="official" type="hidden" id="official" value="0">
                    <input name="tidtager" type="hidden" id="tidtager" value="0">
                    <input name="bestyrelse" type="hidden" id="bestyrelse" value="0">
                    <input name="venteliste" type="hidden" id="venteliste" value="1">
                    <input name="public_mail" type="hidden" id="public_mail" value="1">
</span>
                              </td>
                  </tr>
                </table>
                 
                <input type="hidden" name="MM_insert" value="form1">
              </form>
                  </div>
<!--#include file="sponsors.asp"-->

                        <div class="led">
                                    <%if (RSTid.Fields.Item("timestamp").Value) > date - 2 then%> <!--'Beregn datoforskellen mellem TIDSSTEMPEL og DAGSDATO-->                              
                                          <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="12" height="11">
                                          <param name="movie" value="flash/led.swf">
                                          <param name="quality" value="high">
                                          <embed src="flash/led.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="12" height="11"></embed>
                                          <!--param name="movie" value="flash/ledgrey.swf">
                                          <param name="quality" value="high">
                                          <embed src="flash/ledgrey.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="12" height="11"></embed-->
                                          </object>                                    
                                    <%else%>
                                    <%end if%>
                        </div>
            </div><!--#Her ender GLOBAL_MAIN-->
      </div><!--#Her ender GLOBAL-->
</html>
<%
RSTid.Close()
Set RSTid = Nothing
%>

What's wrong??????

Any help would be highly appreciated!

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2005-10-09 at 11:02:18ID21588932
Tags

null

,

object

,

javascript

,

error

,

length

Topic

Macromedia UltraDev

Participating Experts
2
Points
500
Comments
4

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. Dot leaders
    Is there a way to get Word to produce decent dot leaders (a dotted line between the end of a word and a right-justified page number or word? WordPerfect does this easily. In Word, all I can find is tab stops with leader characters. This requires (I think) resetting all ta...
  2. include/reference a css-stylesheet from within another c…
    Hello Experts, is it possible to include/reference a css-stylesheet from within another css-stylesheet? broesi
  3. Creating a class to represent a CSS StyleSheet
    A WindowsForms application I'm currently working on requires that the user can create their own StyleSheets. The "StyleSheet" object is a collection of "Style" objects, much like a CSS StyleSheet contains a collection of CSS classes. In fact, one require...
  4. alternate stylesheet ie7
    Hi, I use alternate stylesheet with javascript to switch them. It works good in ie6 but ie7 is completely do not show css. What could be the reason.

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: hongjunPosted on 2005-10-15 at 09:55:38ID: 15091787

You may try this

You may try this

function altRowColors(){ //v2.0
  var args = arguments, obj, color0, color1, rowList;
  for(var a = 0; a < args.length; a+=3){
    obj = args[a+0]; color0 = args[a+1]; color1 = args[a+2];
    obj = (isNaN(obj)) ? document.getElementById(obj) : document.getElementsByTagName("TABLE")[obj];
   
    if(obj) {
        rowList = obj.getElementsByTagName("TR");

        for(var i = 0; i < rowList.length; i++) rowList[i].style.backgroundColor = eval('color'+(i % 2));

    }
  }
}


I placed the for loop into the if statement. Problem occurs because obj does not evaluate to true and so rowList is undefined. This resulted in the error if the for loop is outside the if statement.

 

by: siliconbritPosted on 2005-12-10 at 06:25:36ID: 15458620


Why is this posted in the Web Dev Software Section, under the UltraDev package?

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...