Search Search

#1 worldwide
FREE Coding Lessons

since 1996
   THE BEST WAY to learn ASP & Asp.net!
Advertise Here!
click for details
Credits Host:
DiscountASP.net
Server Admin:
The "Team"
Contact Info.
Charles M. Carroll

my Blog

Component Checker by Charles Carroll
determine what components are on your server

The script reads the component.ini file we created and reports whether each of the components in that file can be created.

   filename=/learn/test/componentchecker.asp

<Test Script Below>


<%response.buffer=true%>
<TITLE>componentchecker.asp</TITLE>
<body bgcolor="#FFFFFF">
<% 
dim successSTR, FailSTR, checkSTR
whichfile=server.mappath("component.ini")
Set fs = CreateObject("Scripting.FileSystemObject")
Set thisfile = fs.OpenTextFile(whichfile, 1, False)

counter=0

do UNTIL thisfile.AtEndOfStream
    counter=counter+1
    thisline=thisfile.readline
   attempt=trim(thisline)
    pad="&nbsp;&nbsp;&nbsp;&nbsp;"
    DO WHILE attempt="" AND thisfile.atendofStream=false
        thisline=thisfile.readline
       attempt=trim(thisline)
    LOOP
    If mid(thisline,1,1)="[" then
        ' ignore
        CheckSTR=CheckSTR & thisline & " "
        lastcategory=category
        category=lcase(thisline)
        oldcategory=mid(category,1,Len(category)-1)    
        category=replace(category,"www.","<a href='http://www.")
        IF instr(category,"href")>0 then
            category=mid(category,2)
            category=category & "'>" & oldcategory & "]</a>"
        END IF
        group= "<b>" & category & " component group</b><br>"
        successcount=0
        failcount=0
        thisline=thisfile.readline
        attempt=thisline
        response.flush
    end if
    on  error resume next
    set tempobject=server.createobject(attempt)
    eol="<br>" & vbcrlf
    whicherr=err.number
    If whicherr=0 then
        if successcount=0 then
            successSTR=successSTR & group
        end if
        vleft="&nbsp;(ver="
        vright=")&nbsp;"
        SELECT CASE lcase(attempt)
            CASE "adodb.connection"
                version= vleft & tempobject.version & vright
            CASE ELSE
                version=""
        END SELECT

        successSTR= successSTR & pad &  "<b>" & attempt & version & "</b> successfull!" & eol
        successcount=successcount+1
    else
        if failcount=0 then
            FailSTR=FailSTR & group
        end if
        IF whicherr=-2147221005 THEN
            msg = " is not registered!"
        ELSE
            msg = " failed. Error #" & whicherr
        END IF
        FailSTR= failSTR & pad & "<b>" & attempt & "</b>" & msg & eol
        failcount=failcount+1
    end if
    set tempobject=nothing
loop

thisfile.Close
set thisfile=nothing
set fs=nothing

response.write "Checked: " & checkSTR & "<hr>"
response.write successSTR & "<hr>"
response.write failSTR 
%>

This component.ini file contains a list of typical server components, grouped by type. Type is indicated within [ ] codes. Here is the contents of the current component.ini:

   filename=/learn/test/component.ini

<Test Script Below>


[standard]
mswc.browsertype
mswc.nextlink
scripting.dictionary
scripting.filesystemobject

[ado]
adodb.recordset
adodb.connection
adodb.command

[cdo]
CDONTS.NewMail 

[cyscape]
cyScape.browserObj

[indexserver]
ixsso.Query
ixsso.Util

[Lyris]
Lyris.LCP

[http://msdn.microsoft.com/scripting]
Wscript.Shell

[msfreebies]
iissample.asp2htm
iissample.contentrotator
iissample.registry
iissample.summaryinfos
iissample.tracer
mswc.adrotator
mswc.counters
mswc.myinfo
MSWC.PageCounter
MSWC.PermissionChecker
mswc.tools
mswc.loadbalance

[msXML]
microsoft.XMLHTTP
microsoft.XMLDOM

[www.aspdb.com]
ASPdb.Free
ASPdb.View
ASPdb.Pro
ASPdb.EP

[www.serverobjects.com]
ASPChart.Chart
AspConv.Expert
AspDNS.Lookup
AspFile.FileObj
AspHTTP.Conn
AspImage.Image
AspInet.FTP 
AspMX.Lookup
AspNNTP.Conn
AspPager.Pager
SMTPsvg.Mailer

[www.softartisans.com]
SoftArtisans.FileUp
SoftArtisans.SACheck
SoftArtisans.SASessionPro
SoftArtisans.FileManager
EZsite.Calender
EZsite.CalendarManager
EZsite.WebNotes

[www.active4.com]
ActiveLaunch.Control
ActiveSAR.SearchAndReplace
ActiveShopper.Cart
ActiveShopper.BasketItem
FileTouch.Control
PCAuthX.Authorizer
Prt2Disk.Control
SemClient.Control
SPrinterPro.Object
TimeSpan.Control
WWWPrint.Client

[Zaks Software]
ZaksPop3.Server
JavaPop3.Mailer

[www.persits.com]
Persits.MailSender

[www.oceantek.com]
ASPL.Login

[www.able-consulting.com]
ACI.WhoIs

[www.softwing.com]
Softwing.EventLogReader
Softwing.OdbcRegTool
w3info.w3info.1
InetCtls.Inet.1
Softwing.AspQPerfCounters
SQLOLE.SQLServer
SOFTWING.ASPEventlog
SOFTWING.ASPtear
SOFTWING.EDConverter
SOFTWING.EventLogReader
SOFTWING.FileCache.1
SOFTWING.OdbcRegTool
SOFTWING.LocaleFormatter
SOFTWING.Profiler

[www.dougdean.com]
EZsite.EZuploadLite

[www.algonet.se/~jekman]
lightcom.xBrowser
lightcom.xContent
lightcom.xPop3
lightcom.xSMTP
lightcom.xTree
lightcom.xBrowser
JESoftware.xContent
JESoftware.xPop3
JESoftware.xSMTP
JESoftware.xTree

[tech.dimac.net]
Socket.TCP

[www.de-info.com]
checkemail.maccheckemail

[www.pstruh.cz]
TCPIP.Trace
TCPIP.DNS

[www.dana-net.com/products/aspcomponents/magicregistry]
MagicRegistry.Tricks

Send Us a Holiday Gift!. Charles celebrates Christmas, Jewish holidays, Kwanza, Chinese New Year, Japanese Holidays, Secretary Day, High Muslim Holy Days, Pagan & Wicca holidays, and many more! - send a gift any HOLIDAY. 2004 gift gallery & 2005 gift gallery