S
Steven K
Hello,
I have an include file (../../Connections/pricex.inc). That I use to
declare my variables and build my connection string. I tried using the
following, but got the error: Compiler Error Message: BC30188: Declaration
expected. If I move "Response.WriteFile" statement into the sub block, I
get the error that my variables are not declared.
My question is, where and how do I add the include file?
<script runat="server">
Response.WriteFile ("../../Connections/pricex.inc")
Sub Page_Load(Sender As Object, E As EventArgs)
spSearch = New SqlDataAdapter("sp_web_Search " &
"'FindRegionSubRegion','','',''", cnnSearch)
spSearch.SelectCommand.CommandType = CommandType.StoredProcedure
'Close Out the connection
spSearch = Nothing
cnnSearch.Close : cnnSearch = Nothing
End Sub
</script>
I have an include file (../../Connections/pricex.inc). That I use to
declare my variables and build my connection string. I tried using the
following, but got the error: Compiler Error Message: BC30188: Declaration
expected. If I move "Response.WriteFile" statement into the sub block, I
get the error that my variables are not declared.
My question is, where and how do I add the include file?
<script runat="server">
Response.WriteFile ("../../Connections/pricex.inc")
Sub Page_Load(Sender As Object, E As EventArgs)
spSearch = New SqlDataAdapter("sp_web_Search " &
"'FindRegionSubRegion','','',''", cnnSearch)
spSearch.SelectCommand.CommandType = CommandType.StoredProcedure
'Close Out the connection
spSearch = Nothing
cnnSearch.Close : cnnSearch = Nothing
End Sub
</script>