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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

What is ADOVBS.INC ?

Status
Not open for further replies.

sujitopics

Programmer
Oct 9, 2001
69
KR
Hai Friends
I am new to ASP
I am trying to run the asp - database connectivity programs.
My program is giving error in the following line

<!--#include virtual=&quot;/ASPSAMP/SAMPLES/ADOVBS.INC&quot;-->

actually what is ADOVBS.INC file
where shall i keep this file
I am working on win2k server o.s
my virtual directory name is PBSData.
if possible please tell me where shall i keep this ADOVBS.INC file .
Thanks in advance
Yours
Suji
 
It would probably be most helpfull for you to make a copy of it in your web directory that you plan to use it. I usually make an sub-directory in the web site directory for include files such as adovbs.inc, a db connection script I use on multiple pages, a .css script for layout and color scheme throughout the site, etc, etc.

adovbs.inc is a list of const variables for your asp pages, if I'm not mistaken...specifically for ADO objects. Usually used when making connections to databases, instead of having to remember numeral or hexidecimal values for what you want the connection to do, you can use text. (a variable defined in the adovbs.inc (Active-X Data Objects Visual Basic Script .Include)

For instance, if you were opening a recordset to read only, and move forward only, you'd type:

rs.CursorLocation = 3
rs.Open sql, conn, 0, 1, &H0001

which would tell it to use a client side cursor, move forward only through the database (is faster), Lock Read only (faster, but can't update, append, or delete), and that the command is text rather than working directly with a table. For some, it's easier this way:

rs.CursorLocation = adUseClient
rs.Open sql, conn, adOpenForwardOnly, adLockReadOnly, adCmdText

You don't have to use this way, infact it's a little faster if you use straight numbers, but it can also become confusing if you don't have a really good memmory for numbers. For me, it's just easier to use numbers, plus I don't own a business, this is all on my own server at home which means I can't afford a top of the line power house server, which in-turn means I need every bit of performance I can get out of it. That's just me, you'll have to choose which way is best for you.

Just note, if you want to use the variables as in a situation like above, you must include the adovbs.inc (unless you're using javascript rather than vbscript for your server side programming in which case you need a similar file which I believe (but am not 100% sure) is called ADOJAVAS.INC.

Hope this helps! -Ovatvvon :-Q
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top