× 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.



I figured out how to do what I originally requested. But after a lot of
reading, it seems that javascript is better supported.

Does anyone know how to convert the following vbscript to javascript?

VBSCRIPT to connect to DB2 database and build an html table:
============================================================
Const adOpenStatic = 3
Const adLockOptimistic = 3

Set objConnection = CreateObject("ADODB.Connection")
Set objRecordSet = CreateObject("ADODB.Recordset")

objConnection.Open _
"DSNNAME;USER;PASSWORD"

objRecordSet.Open "SELECT CTNID FROM zfrankk2.wmrtpc10 where crtdt =
20080401 and crtts < 3000 ", _
objConnection, adOpenStatic, adLockOptimistic

objRecordSet.MoveFirst

Do Until objRecordset.EOF

document.write("<tr><td bgcolor='white'><font color='red'>")
document.write(objRecordset.Fields.Item("CTNID"))
document.write("</font></td></tr>")

objRecordSet.MoveNext

Loop

objConnection.Close
============================================================

Thanks,

Frank


-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx] On
Behalf Of Frank Kany
Sent: Wednesday, April 23, 2008 9:19 AM
To: 'web400@xxxxxxxxxxxx'
Subject: [WEB400] vbscript help

Good morning,



Does anyone have any example vbscripts that do the following?

1) Connect to AS400 DB2 file.

2) Dynamically build HTML table from SQL query.

3) Display web page.



Thanks,


Frank


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.