Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB Script Error

Status
Not open for further replies.
Jun 1, 2004
65
US
I've been given a very old code that I need to trouble shoot but can't seem to get pass a certain error everytime I run the script:

Script: Reporter.vbs
Line: 9
Char: 21
Error: Expected end of Statement
Code: 800a0401
Source MS VBScript

Googling the error comes up that it's a punctiation error but I can't seem to find it. I've enclosed a copy of the script to see if anyone else can help me on this.

Thanks
Imports System.Data.SqlClient
Imports System.Web


Module Module1

Sub Main()

Dim connect As New SqlConnection("Initial Catalog = Lumigent; Data Source=sqlserver; User ID=; password = ; Connect Timeout=60")
Dim msgBody As String
Dim UserHeader As String = "Username"
Dim DatabaseHeader As String = "Database"
Dim TableHeader As String = "Table"
Dim OperationHeader As String = "Operation"
Dim CountHeader As String = "Count"
Dim cmdLine As String = System.Environment.CommandLine
 
If that is all of your code, then you have unclosed code blocks and yes, it certainly is not VBScript.

[red]"... isn't sanity really just a one trick pony anyway?! I mean, all you get is one trick, rational thinking, but when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick[/red]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top