Hi, I want to use JScript's HTML Component. I have ScrollTable.htc file that I want to add into JSP file as style behavior. Attached are the files, I am not able to see the effact of .htc behavior at runtime on JSP but if I save the generated HTML source and open it as .html file, I can see the effact of behavior. How can I see the same as runtime JSP page.
Attachment: 1) ScrollTable.htc (HTML component) 2) detail_report.js JSP page that I want to use .htc file 3) DetailReport_2.html Generated HTML source, saved as .html file. Thanks Jasmin <<ScrollTable.htc>> <<detail_report.jsp>> <<DetailReport_2.html>>
<PUBLIC:ATTACH event="ondocumentready" handler="onDocumentReady" />
<SCRIPT language="JScript">
window.alert('reading it');
function onDocumentReady()
{
// Create elements
var tblHeader = this.cloneNode(false);
var tblBody = this.cloneNode(false);
var divCntr = document.createElement("DIV");
// Get column widths
var rgWidths = new Array();
for (var i = 0; i < this.rows[0].cells.length; i++)
{
rgWidths[i] = this.rows[0].cells[i].offsetWidth;
}
// Add header row
var tbdyHeader = document.createElement("TBODY");
tblHeader.appendChild(tbdyHeader);
tblHeader.style.height = 10; /**/
tbdyHeader.appendChild(this.rows[0].cloneNode(true));
// Add body rows
var tbdyBody = document.createElement("TBODY");
tblBody.appendChild(tbdyBody);
for (var i = 1; i < this.rows.length; i++)
{
var oRow = this.rows[i].cloneNode(true);
tbdyBody.appendChild(oRow);
}
// Set up body container
divCntr.style.overflow = "auto";
if (this.bodyHeight)
divCntr.style.height = this.bodyHeight;
window.alert(this.height);
if (this.height) /**/
divCntr.style.height = this.height;/**/
divCntr.appendChild(tblBody);
// Change existing table
for (var i = this.rows.length; i > 0; i--)
{
this.rows[i-1].removeNode(true);
}
var tr1 = this.insertRow();
var td1 = tr1.insertCell();
var tr2 = this.insertRow();
var td2 = tr2.insertCell();
td1.appendChild(tblHeader);
td2.appendChild(divCntr);
// Set column widths of all but the last column
for (var i = 0; i < rgWidths.length - 1; i++)
{
tblHeader.rows[0].cells[i].width = rgWidths[i];
tblBody.rows[0].cells[i].width = rgWidths[i];
}
tblHeader.style.fontSize = "100%";
tblHeader.width = "100%";
tblHeader.style.tableLayout = "fixed";
tblHeader.className = this.headerCSS ? this.headerCSS : "";
tblHeader.border = 0;
tblBody.style.fontSize = "100%";
tblBody.width = "100%";
tblBody.style.tableLayout = "fixed";
tblBody.className = this.bodyCSS ? this.bodyCSS : "";
tblBody.border = 0;
this.cellSpacing = 0;
this.cellPadding = 0;
}
</SCRIPT>
detail_report.jsp
Description: detail_report.jsp
| Project Name | CR# |
|---|---|
| CARD EAST `SAME DAY` HARD POST | 041413 |
| EXCEPTION PROCESSING STANDARDIZATION | 041927 |
| 2003 SPRING ASSOCIATION MANDATES | 041684 |
| MINI CARD CREDIT CARD MASS REISSUE | 041800 |
| CUSTOM BEHAVIOR SCORE GENERATION II | 041473 |
| PAYMENT HIERARCHY PHASE 1 | 041499 |
| CARD/GOVERNMENT PREPAID PAYMENT SOLUTIONS | 039298 |
| POP (PERFORMANCE OPTIMIZATION PRICING) PHASE 3 | 040854 |
| WORKFLOW FOR SM BUS CREDIT APP PROCESSING | 040284 |
| TSYS DCE TO MDE CONVERSION | 040260 |
| TSYS SEVEN DAY PROCESSING - OLIF # 020708 | 040520 |
| AT ATM SOFTWARE CHANGE PROCESS IMPROVEMENT | 040730 |
| HELOC ACCESS CARD BALANCE TRANSFER ENHANCEMENTS | 039107 |
| CHANGES TO PLATINUM THRESHOLDS - PHASE I | 041367 |
| CONVERSION OF CFA INTERFACES TO BCC | 039325 |
| 021025 CALIFORNIA SB 168 SECURITY FREEZE | 041011 |
| ELECTRONIC PAYMENTS USING MME | 037522 |
| AUTO CHARGEBACK ACTIVATION | 040872 |
| OLIF #020675 2003 ACQUISITIONS NEW ACCOUNT DIRECT MAIL PROGRAMS | 041196 |
| 2002 YEAR END SUMMARY FOR CREDIT CARD STATEMENTS OLIF 020216 | 040939 |
| 1.9% INTRO RATE FOR COBRANDS IN ASSOCIATE BANKING | 040934 |

