Vb Script to Output in HTML

Posted on 2011-10-02
Last Modified: 2012-05-12
I an trying to output in HTML from a VbScript code, but I keep getting errors.. Here is my output but when I do something like this OutWriteline "<FontSize="14">" it breaks. I am sure I am doing something wrong.

oOut.WriteLine "<htmL>"
oOut.WriteLine "<Body>"
oOut.WriteLine "<FontSize="14">"
oOut.WriteLine "<b><FontSize=14">Testing Session Output </b></font>"
oOut.WriteLine "</font>"
oOut.WriteLine "<Table>"
oOut.WriteLine "<TR>"
oOut.WriteLine(" <td>" & SessionId(0).text & "</td>")
oOut.WriteLine "</TR>"
oOut.WriteLine "</body>"
oOut.WriteLine "</html>"

Question by:drezner7
    LVL 29

    Accepted Solution

    simple reason, " inside a string doesn't work out. But html also works without quotes around attribute values, or single quotes instead.


    oOut.WriteLine "<FontSize='14'>"

    Bye, Olaf.

    Author Closing Comment

    Thank you so much. That is just what I needed

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Unlike scripting languages such as C# where a semi-colon is used to indicate the end of a command, Microsoft's VBScript language relies on line breaks to determine when a command begins and ends. As you can imagine, this quickly results in messy cod…
    Recently I finished a vbscript that I thought I'd share.  It uses a text file with a list of server names to loop through and get various status reports, then writes them all into an Excel file.  Originally it was put together for our Altiris server…
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    758 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now