I noticed this earlier in another post.
This is the statement used to retrieve sigs
if strSignatures = "1" and strDSignatures <> "1" then
if Request.Form("sig") = "yes" and GetSig(strDBNTUserName) <> " " then
txtMessage = txtMessage & vbNewline & vbNewline & ChkString(GetSig(strDBNTUserName), "signature" )
end if
end if
as you can see, if all conditions are right, it uses the GetSig function twice. Two trips to the db.
This will bring it down to one
if strSignatures = "1" and strDSignatures <> "1" then
if Request.Form("sig") = "yes" then
txtSig = GetSig(strDBNTUserName)
if trim(txtSig) <> "" then
txtMessage = txtMessage & vbNewline & vbNewline & ChkString(txtSig, "signature" )
end if
end if
end if
<