I think you misunderstood Shawn. You're not having an issue when you call the DBConnOpen() function, but you have edited or incorrectly copied the function itself.

Look at the function header in your script and look at what it should be

Yours

Quote:


Function DBConnOpen($objConn, optional $ConnTimeout, optional $CmdTimeout)
.
.
.
EndFunction





What it should be

Quote:


Function DBConnOpen($ConnDSN, optional $ConnTimeout, optional $CmdTimeout)
.
.
.
EndFunction





Here's the UDF as it's posted DBConnOpen()