× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Ok,
I think I might have figured part of this out.  I'm using DHTML <DIV> tags 
to give me the appearance of Tabbed panels on my webpage.  I'm just going 
to post the HTML so that you can see what it is.  My question is, if I put 
the form tags around the entire thing, is the <DIV> tags the reason I 
can't seem to access the elements that are contained in it?
Here's my HTML code.  I've removed the unimportant parts.  Specfically, 
the changeBulkRecord() is the part that I can't see to get working.  I get 
an undefined when the alert(i) displays.  I can't figure it out.  I've 
bolded the code.  Any help would be really appreciated.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<HTML>
<HEAD>
<%@ page 
language="java"
contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"
%>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<META NAME="GENERATOR" CONTENT="IBM WebSphere Studio">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
<LINK REL="stylesheet" TYPE="text/css"
 HREF="http://citynet/intranet/sjintranet.nsf/intranetStyle?OpenPage";>
<TITLE>Customer Information</TITLE>
<STYLE>
.conts  {visibility:hidden}
.tab    {       border-top:solid thin #E0E0E0;
                        border-right:solid thin CCCCCC;
                        border-left:solid thin #E0E0E0;
                        font-size:10pt;
                        text-align:center;
                        font-weight:normal}

.selTab {       border-left:solid thin white;
                        border-top:solid thin white;
                        border-right:solid thin black;
                        font-weight:bold;
                        text-align:center}

</STYLE>
<SCRIPT LANGUAGE="javascript" SRC="trimFunctions.js">
</SCRIPT>
<SCRIPT LANGUAGE="javascript">
//a public function that the container uses to pass in values for the 
labels
function public_Labels(label1, label2){
 
        t1.innerText = label1;
        t2.innerText = label2;
}

//a public function that the container uses to pass in values for the card 
containers
function public_Contents(contents1, contents2){

        t1Contents.innerHTML = contents1;
        t2Contents.innerHTML = contents2;
 
        init();
}

//this is the tab switching function
var currentTab;
var tabBase;

//sets the default display to tab 1
function init(){
                <%if (request.getAttribute("type").equals("metal")){%>
                tabContents.innerHTML = t2Contents.innerHTML;
                currentTab = t2;
                tabBase = t2base;
                <%}else{%>
                tabContents.innerHTML = t1Contents.innerHTML;
                currentTab = t1;
                tabBase = t1base;
                <%}%>
                <%
                if (request.getAttribute("reloadStreet")!=null){
                        if 
(request.getAttribute("reloadStreet").equals("yes")){
                %>
                                parent.left.location.reload(true);
                <% 
                        }
                }
                if (request.getAttribute("customerExists")!=null){
                        if 
(request.getAttribute("customerExists").equals("yes")){
                %>
                                alert("Customer already exists in 
database! Cannot add!");
                <%
                        }
                }
                %>
} 

function changeTabs(){

        if(window.event.srcElement.className == "tab"){

                currentTab.className = "tab";

                tabBase.style.backgroundColor = "white";

                currentTab = window.event.srcElement;

                tabBaseID = currentTab.id + "base";

                tabContentID = currentTab.id + "Contents";

                tabBase = document.all(tabBaseID);

                tabContent = document.all(tabContentID);

                currentTab.className = "selTab";
 
                tabBase.style.backgroundColor = "";

                tabContents.innerHTML = tabContent.innerHTML;

        }
}
// end of tabbed code

//code for add remove from the list boxes
function addOption(selectObject,optionText,optionValue) {
    if ( !recheck (selectObject, optionText, optionValue) ){
      var optionObject = new Option(optionText,optionValue);
      var optionRank = selectObject.options.length;
      selectObject.options[optionRank]=optionObject;
    }
    else{
        alert("Option is already present!");
    } 

}

function deleteOption(selectObject,optionRank) {
    if (selectObject.options.length!=0) { 
selectObject.options[optionRank]=null; }
}

function recheck (selectObject, optionText, optionValue){ 
  var sltbool = false;
  for (i=0; i<selectObject.options.length; i++){
     if (optionText == selectObject.options[i].text ||  optionValue == 
selectObject.options[i].value ){
        sltbool = true;
        break;
     }
  } 
  return sltbool;
}

function listDeleteBulk() 
  {
    if (frmMain.pickupItemsBulk.selectedIndex!=-1) 
    {
 
deleteOption(frmMain.pickupItemsBulk,frmMain.pickupItemsBulk.selectedIndex);
    } 
    else 
    {
        alert("Select an item and click Remove!");
    }
  }
function listAddBulk() {
    if (frmMain.listItemsBulk.selectedIndex!=-1) {
        var desc = 
frmMain.listItemsBulk.value.substring(frmMain.listItemsBulk.value.lastIndexOf(")")+2);
 addOption(frmMain.pickupItemsBulk,desc,frmMain.listItemsBulk.value);
    } else {
        alert("Select item to be picked up!");
    }
}
function listDeleteMetal() 
  {
    if (frmMain.pickupItemsMetal.selectedIndex!=-1) 
    {
 
deleteOption(frmMain.pickupItemsMetal,frmMain.pickupItemsMetal.selectedIndex);
    } 
    else 
    {
        alert("Select an item and click Remove!");
    }
  }
function listAddMetal() {
    if (frmMain.listItemsMetal.selectedIndex!=-1) {
        var desc = 
frmMain.listItemsMetal.value.substring(frmMain.listItemsMetal.value.lastIndexOf(")")+2);
 addOption(frmMain.pickupItemsMetal,desc,frmMain.listItemsMetal.value);
    } else {
        alert("Select item to be picked up!");
    }
}

function changeBulkRecord(){
        var i = document.frmMain.callRecDateBulk.selectedIndex;
        alert(i);
        var a = "ChangeGarbageRec?selectedIndex=" + i + "&type=bulk";
        frmMain.action = a;
        frmMain.submit();
}

function changeMetalRecord(){
        var i = document.frmMain.callRecDateMetal.selectedIndex;
        var a = "ChangeGarbageRec?selectedIndex=" + i + "&type=metal";
        frmMain.action = a;
        frmMain.submit();
}
</SCRIPT>
</HEAD>
<BODY onclick="changeTabs()" onload="init()" BGCOLOR=99CCFF>
<jsp:useBean class="com.csj.bulkgarbage.Customer" id="customer" 
scope="session"></jsp:useBean>
<jsp:useBean id="vBulkGarbage" scope="session" 
class="java.util.Vector"></jsp:useBean>
<jsp:useBean id="vMetalGarbage" scope="session" 
class="java.util.Vector"></jsp:useBean>
<jsp:useBean id="vGarbagePickList" scope="session" 
class="java.util.Vector"></jsp:useBean>
<jsp:useBean id="vReasonCode" scope="session" 
class="java.util.Vector"></jsp:useBean>
<jsp:useBean id="disabled" scope="session" 
class="java.lang.String"></jsp:useBean>
<jsp:useBean id="enabled" scope="session" 
class="java.lang.String"></jsp:useBean>
<jsp:useBean id="gdisabled" scope="session" 
class="java.lang.String"></jsp:useBean>
<jsp:useBean id="genabled" scope="session" 
class="java.lang.String"></jsp:useBean>
<jsp:useBean id="vStreet" scope="session" 
class="java.util.Vector"></jsp:useBean>

<%
com.csj.bulkgarbage.Customer c = customer;
%>
<FORM NAME="frmMain" METHOD="post">
<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" width="550">
        <TBODY>
                <TR BGCOLOR="#D6D6D6">
                        <TD COLSPAN="2"><B>Customer Info:</B><INPUT 
TYPE=HIDDEN NAME="custId" 
VALUE="<%out.print(c.getCustId().trim());%>"></TD>
                        <TD COLSPAN="3"><B>Location Info:</B></TD>
                </TR>
                <TR>
                        <TD VALIGN="top" width="80"><B>First 
Name:</B></TD>
                        <TD VALIGN="top" width="200"><INPUT 
NAME="firstName"
 VALUE="<%out.print(c.getFirstName().trim());%>" MAXLENGTH="40"
                                CLASS="field" SIZE="40" 
<%out.print(disabled);%>></TD>
                        <TD VALIGN="top" width="50" 
align="right"><B>Civic</B></TD>
                        <TD VALIGN="top" width="50" 
align="center"><B>Unit</B></TD>
                        <TD VALIGN="top" width="170" 
align="left"><B>Street</B></TD>
                </TR>
                <TR>
                        <TD VALIGN="top" width="80"><B>Last Name:</B></TD>
                        <TD VALIGN="top" width="200"><INPUT 
NAME="lastName"
 VALUE="<%out.print(c.getLastName().trim());%>" MAXLENGTH="40"
                                CLASS="field" SIZE="40" 
<%out.print(disabled);%>></TD>
                        <TD VALIGN="top" width="50" 
align="right"><%out.print(c.getCivicNo().trim());%></TD>
                        <TD VALIGN="top" width="50" 
align="center"><%out.print(c.getUnit().trim());%></TD>
                        <TD VALIGN="top" width="170" 
align="left"><%out.print(c.getStreetName().trim());%></TD>
                </TR>
                <TR>
                        <TD VALIGN="top" width="80"><B>Phone:</B></TD>
                        <TD VALIGN="top" width="200"><INPUT NAME="phone"
                                VALUE="<%out.print(c.getPhoneNo());%>" 
MAXLENGTH="7"
                                CLASS="field" SIZE="8" 
<%out.print(disabled);%>></TD>
                        <TD COLSPAN="3" VALIGN="top" 
width="270"><B>Garbage Area: 
</B><%out.print(c.getGarbageArea().trim());%></TD>
                </TR>
                <TR>
                        <TD VALIGN="top" width="80"><B>Comments:</B></TD>
                        <TD VALIGN="top" COLSPAN="5" width="470"><INPUT 
NAME="comments"
 VALUE="<%out.print(c.getComments().trim());%>" MAXLENGTH="100"
                                CLASS="field" SIZE="75" 
<%out.print(disabled);%>></TD>
                </TR>
                <TR>
                        <TD COLSPAN="5">
                        <TABLE ALIGN="LEFT" BORDER="0">
                                <TBODY>
                                        <TR>
                                                <TD ALIGN="LEFT"><INPUT 
TYPE="BUTTON" NAME="newCustomerButton"
                                                        VALUE="New" 
CLASS="Button1" ONCLICK="newCustomer()" <%out.print(enabled);%>></TD>
                                                <TD ALIGN="LEFT"><INPUT 
TYPE="BUTTON" NAME="editCustomerButton"
                                                        VALUE="Edit" 
CLASS="Button1" ONCLICK="editCustomer()" <%out.print(enabled);%>></TD>
                                                <TD ALIGN="LEFT"><INPUT 
TYPE="BUTTON" NAME="saveCustomerButton"
                                                        VALUE="Save" 
CLASS="Button1" ONCLICK="saveCustomer()" <%out.print(disabled);%>></TD>
                                                <TD ALIGN="LEFT"><INPUT 
TYPE="BUTTON" NAME="cancelCustomerButton"
                                                        VALUE="Cancel" 
CLASS="Button1" ONCLICK="cancelCustomer()" <%out.print(disabled);%>></TD>
                                        </TR>
                                </TBODY>
                        </TABLE>
                        </TD>
                </TR>
        </TBODY>
</TABLE>
<HR>

<DIV STYLE="border:none thin gray">

<TABLE CELLPADDING=0 CELLSPACING=0 bgcolor=CCCCCC WIDTH="550">
<%if(request.getAttribute("type").equals("bulk")){%>
        <TR>
                <TD ID=t1 CLASS=selTab HEIGHT=25 WIDTH=50%>Bulk</TD>
                <TD ID=t2 CLASS=tab HEIGHT=25 WIDTH=50%>Metal</TD>
        </TR>
        <TR>
                <TD ID=t1base STYLE="height:2; border-left:solid thin 
white"></TD>
                <TD ID=t2base STYLE="height:2; 
background-color:white"></TD> 
        </TR>
<%} else { %>
        <TR>
                <TD ID=t1 CLASS=tab HEIGHT=25 WIDTH=50%>Bulk</TD>
                <TD ID=t2 CLASS=selTab HEIGHT=25 WIDTH=50%>Metal</TD>
        </TR>
        <TR>
                <TD ID=t1base STYLE="height:2; 
background-color:white"></TD>
                <TD ID=t2base STYLE="height:2; border-left:solid thin 
white"></TD>
        </TR>
<% } %>

        <TR>
                <TD HEIGHT="*" COLSPAN=2 ID=tabContents
 STYLE="        border-left:solid thin white;
        border-bottom:solid thin white;
        border-right:solid thin white"></TD>

        </TR>
</TABLE>
</DIV>

<DIV CLASS=conts ID=t1Contents>
<%
        int iBulkIndex = 
((Integer)session.getAttribute("iBulkIndex")).intValue();
        int iBulkPickUpIndex = 
((Integer)session.getAttribute("iBulkPickUpIndex")).intValue();
        com.csj.bulkgarbage.BulkGarbageSchedMaster b = 
(com.csj.bulkgarbage.BulkGarbageSchedMaster) vBulkGarbage.get(iBulkIndex);
%>
<TABLE CELLSPACING="0" CELLPADDING="0" BORDER="0" WIDTH="550">
        <TBODY>
                <TR>
                        <TD width="150"><B>Bulk Garbage Id#</B></TD>
                        <TD 
width="150"><%out.print(b.getGarbageId());%></TD>
                        <TD width="50"></TD>
                        <TD width="150"></TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Date Called</B></TD>
                        <TD width="150"><SELECT NAME="callRecDateBulk" 
style="width: 150px;" onChange="changeBulkRecord();" 
<%out.print(genabled);%>>
                        <%
                        for (int i = 0; i < vBulkGarbage.size(); i++){
                                com.csj.bulkgarbage.BulkGarbageSchedMaster 
bg = (com.csj.bulkgarbage.BulkGarbageSchedMaster) vBulkGarbage.get(i);
                        %>
                        <OPTION 
value="<%out.print(bg.getCallRecDate());%>"<%if(i == 
iBulkIndex){out.print(" 
SELECTED");}%>><%out.print(bg.getCallRecDateString());%></OPTION> 
                        <%
                        }
                        %></SELECT></TD>
                        <TD width="50"></TD>
                        <TD width="150"></TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Pick Up Date</B></TD>
                        <TD width="150">
                        <SELECT NAME="schedPickUpDateBulk" style="width: 
150px;" onChange="changePickupDateBulk(pickupItemsBulk)" 
<%out.print(gdisabled);%>>
                        <%
                                com.csj.bulkgarbage.BulkGarbageSchedMaster 
bg = (com.csj.bulkgarbage.BulkGarbageSchedMaster) 
vBulkGarbage.get(iBulkIndex);
                                if (bg.getDateSentToContractor()!=0){
                        %>
                        <OPTION 
value="<%out.print(bg.getSchedPickUpDate());%>" 
<%out.print("SELECTED");%>><%out.print(bg.getSchedPickUpDateString());%></OPTION>
                        <%}else{
                                java.util.Vector vPus = 
bg.getPickupSchedule();
                                for (int i=0; i<vPus.size(); i++){
                                        com.csj.bulkgarbage.PickUpSchedule 
p = (com.csj.bulkgarbage.PickUpSchedule) vPus.get(i);
                        %>
                        <OPTION value="<%out.print(p.getPickupDate());%>" 
<%if(i == iBulkPickUpIndex){out.print("SELECTED");} 
%>><%out.print(p.getPickupDateString());%></OPTION>
                        <%
                                        }
                                }
                        %>
                        </SELECT></TD>
                        <TD width="50"></TD>
                        <TD width="150"><B>Appointment #</B></TD>
                        <TD 
width="50"><B><%out.print(b.getAppointmentCount());%></B></TD>
                </TR>
                <TR>
                        <TD width="150"></TD>
                        <TD align="center" valign="bottom" width="102">
                        <B>Item Pick List</B>
                        </TD>
                        <TD width="50"></TD>
                        <TD width="150" align="center" valign="bottom">
                        <B>Items To Be Picked Up</B>
                        </TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Description</B></TD>
                        <TD width="150">
                        <SELECT MULTIPLE SIZE="8" NAME="listItemsBulk" 
ID="listItemsBulkID" ONDBLCLICK="listAddBulk()" style="width: 150px;" 
<%out.print(gdisabled);%>>
                        <%
                        for (int i = 0; i < vGarbagePickList.size(); i++){
                                com.csj.bulkgarbage.GarbageMasterPickList 
gm = 
(com.csj.bulkgarbage.GarbageMasterPickList)vGarbagePickList.elementAt(i);
                                if 
(gm.getGarbageDescId().substring(0,1).equals("B")){
                                        out.print("<OPTION value=\"(" + 
gm.getGarbageDescId() + ") " + gm.getGarbageDescription().trim() + "\">" + 
gm.getGarbageDescription().trim() + "</OPTION>");
                                }
                        }
                        %>
                        </SELECT>
                        </TD>
                        <TD width="50" ALIGN=CENTER>
                                <INPUT ONCLICK="listDeleteBulk()" 
TYPE="BUTTON" CLASS="Button1" NAME="removeItemBulk" VALUE="&lt;&lt;" 
<%out.print(gdisabled);%>>
                                <BR>
                                <INPUT ONCLICK="listAddBulk()" 
TYPE="BUTTON" CLASS="Button1" NAME="addItemBulk" VALUE="&gt;&gt;" 
<%out.print(gdisabled);%>>
                        </TD>
                        <TD width="150">
                        <SELECT MULTIPLE SIZE="8" NAME="pickupItemsBulk" 
ID="pickupItemsBulkID" ONDBLCLICK="listDeleteBulk()" style="width: 150px;" 
<%out.print(gdisabled);%>>
                        <%
                        String otherCheckedBulk = "";
                        String otherDescriptionBulk = "";
                        for (int j = 0; j < b.getNumberOfDetail(); j++){
                                com.csj.bulkgarbage.BulkGarbageSchedDetail 
d = (com.csj.bulkgarbage.BulkGarbageSchedDetail) b.getGarbageDetail(j);
 if(!(d.getGarbageDescriptionId().trim().equals(""))){
 if(!(d.getGarbageDescriptionId().trim().equals("99999"))){
                                                out.print("<OPTION 
value=\"(" + d.getGarbageDescriptionId() + ") " + 
d.getItemDescription().trim() + "\">" + d.getItemDescription().trim() + 
"</OPTION>");
                                        } else {
                                                otherCheckedBulk = 
"CHECKED";
                                                otherDescriptionBulk = 
d.getItemDescription().trim();
                                        }
                                }
                        }
                        %>
                        </SELECT>
                        </TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"></TD>
                        <TD width="150"><INPUT TYPE="CHECKBOX" 
NAME="otherBulk" <%out.print(otherCheckedBulk);%> 
<%out.print(gdisabled);%>><B>Other</B></TD>
                        <TD width="50"></TD>
                        <TD width="200" COLSPAN="2"><INPUT 
NAME="otherDescBulk" VALUE="<%out.print(otherDescriptionBulk);%>" 
CLASS="field" MAXLENGTH="40" SIZE="30" <%out.print(gdisabled);%>></TD>
                </TR>
                <TR>
                <TD COLSPAN="5"><BR></TD>
                </TR>
                <TR>
                        <TD ALIGN="LEFT" COLSPAN=2 WIDTH="300">
                                <INPUT TYPE="BUTTON" 
NAME="newBulkGarbageButton"
                                        VALUE="New" CLASS="Button1" 
ONCLICK="newBulkGarbage()" <%out.print(genabled);%>>
                                <INPUT TYPE="BUTTON" 
NAME="editBulkGarbageButton"
                                        VALUE="Edit" CLASS="Button1" 
ONCLICK="editBulkGarbage()" <%out.print(genabled);%>>
                                <INPUT TYPE="BUTTON" 
NAME="saveBulkGarbageButton"
                                        VALUE="Save" CLASS="Button1" 
ONCLICK="validateBulkGarbage(pickupItemsBulk)"<%out.print(gdisabled);%>>
                                <INPUT TYPE="BUTTON" 
NAME="cancelBulkGarbageButton"
                                        VALUE="Cancel" CLASS="Button1" 
ONCLICK="cancelBulkGarbage()" <%out.print(gdisabled);%>>
                        </TD>
                        <TD width="50"></TD>
                        <TD width="150"></TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD COLSPAN="5" width="550"><HR></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Status</B></TD>
                        <TD 
width="150"><%out.print(b.getStatus().trim());%></TD>
                        <TD width="50"><B>Reason</B></TD>
                        <TD 
width="150"><%out.print(b.getStatusReasonCode().trim());%></TD>
                        <TD width="50"></TD>
                </TR>
        </TBODY>
</TABLE>
</DIV>
<DIV CLASS=conts ID=t2Contents>
<%
        int iMetalIndex = 
((Integer)session.getAttribute("iMetalIndex")).intValue();
        int iMetalPickUpIndex = 
((Integer)session.getAttribute("iMetalPickUpIndex")).intValue();
        com.csj.bulkgarbage.BulkGarbageSchedMaster m = 
(com.csj.bulkgarbage.BulkGarbageSchedMaster) 
vBulkGarbage.get(iMetalIndex);
%>
<TABLE CELLSPACING="0" CELLPADDING="0" BORDER="0" WIDTH="550">
        <TBODY>
                <TR>
                        <TD width="150"><B>Metal Garbage Id#</B></TD>
                        <TD 
width="150"><%out.print(m.getGarbageId());%></TD>
                        <TD width="50"></TD>
                        <TD width="150"></TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Date Called</B></TD>
                        <TD width="150"><SELECT NAME="callRecDateMetal" 
style="width: 150px;" onChange="changeMetalRecord(this.form)" 
<%out.print(genabled);%>>
                        <%
                        for (int i = 0; i < vMetalGarbage.size(); i++){
                                com.csj.bulkgarbage.BulkGarbageSchedMaster 
mg = (com.csj.bulkgarbage.BulkGarbageSchedMaster) vMetalGarbage.get(i);
                        %>
                        <OPTION 
value="<%out.print(mg.getCallRecDate());%>"<%if(i == 
iMetalIndex){out.print(" 
SELECTED");}%>><%out.print(bg.getCallRecDateString());%></OPTION> 
                        <%
                        }
                        %></SELECT></TD>
                        <TD width="50"></TD>
                        <TD width="150"></TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Pick Up Date</B></TD>
                        <TD width="150">
                        <SELECT NAME="schedPickUpDateMetal" style="width: 
150px;" onChange="changePickupDateMetal(pickupItemsMetal)" 
<%out.print(gdisabled);%>>
                        <%
                                com.csj.bulkgarbage.BulkGarbageSchedMaster 
mg = (com.csj.bulkgarbage.BulkGarbageSchedMaster) 
vMetalGarbage.get(iMetalIndex);
                                if (bg.getDateSentToContractor()!=0){
                        %>
                        <OPTION 
value="<%out.print(bg.getSchedPickUpDate());%>" 
<%out.print("SELECTED");%>><%out.print(bg.getSchedPickUpDateString());%></OPTION>
                        <%}else{
                                java.util.Vector vPus = 
bg.getPickupSchedule();
                                for (int i=0; i<vPus.size(); i++){
                                        com.csj.bulkgarbage.PickUpSchedule 
p = (com.csj.bulkgarbage.PickUpSchedule) vPus.get(i);
                        %>
                        <OPTION value="<%out.print(p.getPickupDate());%>" 
<%if(i == iMetalPickUpIndex){out.print("SELECTED");} 
%>><%out.print(p.getPickupDateString());%></OPTION>
                        <%
                                        }
                                }
                        %>
                        </SELECT></TD>
                        <TD width="50"></TD>
                        <TD width="150"><B>Appointment #</B></TD>
                        <TD 
width="50"><B><%out.print(m.getAppointmentCount());%></B></TD>
                </TR>
                <TR>
                        <TD width="150"></TD>
                        <TD align="center" valign="bottom" width="102">
                        <B>Item Pick List</B>
                        </TD>
                        <TD width="50"></TD>
                        <TD width="150" align="center" valign="bottom">
                        <B>Items To Be Picked Up</B>
                        </TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Description</B></TD>
                        <TD width="150">
                        <SELECT MULTIPLE SIZE="8" NAME="listItemsMetal" 
ID="listItemsMetalID" ONDBLCLICK="listAddMetal()" style="width: 150px;" 
<%out.print(gdisabled);%>>
                        <%
                        for (int i = 0; i < vGarbagePickList.size(); i++){
                                com.csj.bulkgarbage.GarbageMasterPickList 
gm = 
(com.csj.bulkgarbage.GarbageMasterPickList)vGarbagePickList.elementAt(i);
                                if 
(gm.getGarbageDescId().substring(0,1).equals("M")){
                                        out.print("<OPTION value=\"(" + 
gm.getGarbageDescId() + ") " + gm.getGarbageDescription().trim() + "\">" + 
gm.getGarbageDescription().trim() + "</OPTION>");
                                }
                        }
                        %>
                        </SELECT>
                        </TD>
                        <TD width="50" ALIGN=CENTER>
                                <INPUT ONCLICK="listDeleteMetal()" 
TYPE="BUTTON" CLASS="Button1" NAME="removeItemMetal" VALUE="&lt;&lt;" 
<%out.print(gdisabled);%>>
                                <BR>
                                <INPUT ONCLICK="listAddMetal()" 
TYPE="BUTTON" CLASS="Button1" NAME="addItemMetal" VALUE="&gt;&gt;" 
<%out.print(gdisabled);%>>
                        </TD>
                        <TD width="150">
                        <SELECT MULTIPLE SIZE="8" NAME="pickupItemsMetal" 
ID="pickupItemsMetalID" ONDBLCLICK="listDeleteMetal()" style="width: 
150px;" <%out.print(gdisabled);%>>
                        <%
                        String otherCheckedMetal = "";
                        String otherDescriptionMetal = "";
                        for (int j = 0; j < m.getNumberOfDetail(); j++){
                                com.csj.bulkgarbage.BulkGarbageSchedDetail 
d = (com.csj.bulkgarbage.BulkGarbageSchedDetail) m.getGarbageDetail(j);
 if(!(d.getGarbageDescriptionId().trim().equals(""))){
 if(!(d.getGarbageDescriptionId().trim().equals("99999"))){
                                                out.print("<OPTION 
value=\"(" + d.getGarbageDescriptionId() + ") " + 
d.getItemDescription().trim() + "\">" + d.getItemDescription().trim() + 
"</OPTION>");
                                        } else {
                                                otherCheckedMetal = 
"CHECKED";
                                                otherDescriptionMetal = 
d.getItemDescription().trim();
                                        }
                                }
                        }
                        %>
                        </SELECT>
                        </TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD width="150"></TD>
                        <TD width="150"><INPUT TYPE="CHECKBOX" 
NAME="otherMetal" <%out.print(otherCheckedMetal);%> 
<%out.print(gdisabled);%>><B>Other</B></TD>
                        <TD width="50"></TD>
                        <TD width="200" COLSPAN="2"><INPUT 
NAME="otherDescMetal" VALUE="<%out.print(otherDescriptionMetal);%>" 
CLASS="field" MAXLENGTH="40" SIZE="30" <%out.print(gdisabled);%>></TD>
                </TR>
                <TR>
                <TD COLSPAN="5"><BR></TD>
                </TR>
                <TR>
                        <TD ALIGN="LEFT" COLSPAN=2 WIDTH="300">
                                <INPUT TYPE="BUTTON" 
NAME="newMetalGarbageButton"
                                        VALUE="New" CLASS="Button1" 
ONCLICK="newMetalGarbage()" <%out.print(genabled);%>>
                                <INPUT TYPE="BUTTON" 
NAME="editMetalGarbageButton"
                                        VALUE="Edit" CLASS="Button1" 
ONCLICK="editMetalGarbage()" <%out.print(genabled);%>>
                                <INPUT TYPE="BUTTON" 
NAME="saveMetalGarbageButton"
                                        VALUE="Save" CLASS="Button1" 
ONCLICK="validateMetalGarbage( 
pickupItemsMetal)"<%out.print(gdisabled);%>>
                                <INPUT TYPE="BUTTON" 
NAME="cancelMetalGarbageButton"
                                        VALUE="Cancel" CLASS="Button1" 
ONCLICK="cancelMetalGarbage()" <%out.print(gdisabled);%>>
                        </TD>
                        <TD width="50"></TD>
                        <TD width="150"></TD>
                        <TD width="50"></TD>
                </TR>
                <TR>
                        <TD COLSPAN="5" width="550"><HR></TD>
                </TR>
                <TR>
                        <TD width="150"><B>Status</B></TD>
                        <TD 
width="150"><%out.print(m.getStatus().trim());%></TD>
                        <TD width="50"><B>Reason</B></TD>
                        <TD 
width="150"><%out.print(m.getStatusReasonCode().trim());%></TD>
                        <TD width="50"></TD>
                </TR>
        </TBODY>
</TABLE>
</DIV>
</FORM>
</BODY>
</HTML>


Ron Power
Programmer
Information Services
City Of St. John's, NL
P.O. Box 908
St. John's, NL
A1C 5M2
Tel: 709-576-8132
Email: rpower@xxxxxxxxxx
Website: http://www.stjohns.ca/
___________________________________________________________________________
Success is going from failure to failure without a loss of enthusiasm. - 
Sir Winston Churchill




RPower@xxxxxxxxxx 
Sent by: java400-l-bounces@xxxxxxxxxxxx
10/05/2005 04:03 PM
Please respond to
Java Programming on and around the iSeries / AS400 
<java400-l@xxxxxxxxxxxx>


To
"Java Programming on and around the iSeries / AS400" 
<java400-l@xxxxxxxxxxxx>
cc

Subject
JavaScript help






<TD width="150"><SELECT NAME="callRecDateBulk" style="width: 150px;" 
onChange=
"javascript:alert(document.frmMain.callRecDateBulk.selectedIndex);">

Can someone please tell me why when I change the select box 
callRecDateBulk I get the alert window showing "Undefined"?
My form is defined as:
<FORM NAME="frmMain" METHOD="post">

For some reason this is giving me fits and I can't figure it out.  This 
should return the selected index of the drop down box yes?

Ron Power
Programmer
Information Services
City Of St. John's, NL
P.O. Box 908
St. John's, NL
A1C 5M2
Tel: 709-576-8132
Email: rpower@xxxxxxxxxx
Website: http://www.stjohns.ca/
___________________________________________________________________________
Success is going from failure to failure without a loss of enthusiasm. - 
Sir Winston Churchill
-- 
This is the Java Programming on and around the iSeries / AS400 (JAVA400-L) 
mailing list
To post a message email: JAVA400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/java400-l
or email: JAVA400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/java400-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.