|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
What does these means?
can anyone tell me what this means? please!!
Set objConn = Server.CreateObject("ADODB.Connection") objConn.Open Application("strConnect") strList = "select tbl_dep.ch_depid, ch_depname from tbl_dep ORDER by ch_depname" Set objRs = Server.CreateObject ("ADODB.Recordset") objRs.Open strList, objConn while not objRs.eof Response.Write "<li><a href='#"&objRs("ch_depid")&"'>"&objRs("ch_depname")&"</a></li>" objRs.movenext wend |
|
#2
|
||||
|
||||
|
This is an ASP code snippet that opens a connection to a database, then queries that database to return a recordset of data which is then looped though to display as a list on the browser.
__________________
-
thought-after | my thoughts on web development Get Firefox, the developers browser Budget hosting - recommended [/left] |
|
#3
|
|||
|
|||
|
okay
What does 'wend' means? its at the end of the code...
|
|
#4
|
||||
|
||||
|
It close the WHILE loop and is short for WHILE END.
You would be better off visiting a tutorial site than asking questions about language syntax here. Try visiting w3schools.com for a start. |
|
#5
|
|||
|
|||
|
ok
Thanks for the tips. Will come back if i still got problem with asp.
|
|
#6
|
||||
|
||||
|
No problem. Happy to help, but there are better resouces for you out there for questions like this.
|
|
#7
|
|||
|
|||
|
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified /medical/viewStaffInfo_1.asp, line 4 ----------------------------------------------------------- line 4 is ( conn.open Application("strConn") ) How to fix this? What driver to install? |
|
#8
|
||||
|
||||
|
What's the connection string value in the application variable strConn?
|
|
#9
|
|||
|
|||
|
Line2 dim conn,rs
Line3 set conn=Server.CreateObject("ADODB.Connection") Line4 conn.open Application("strConn") . . . sql = " select * from staff" Set rs = Server.CreateObject("ADODB.Recordset") rs.open sql, conn something like this.... |
|
#10
|
||||
|
||||
|
OK, this line:
conn.open Application("strConn") says: Quote:
If you do not have an application level variable called strConn then you are going to get errors like the one you have. |
![]() |
| Viewing: ASP Free Forums > Other > Programming Help > What does these means? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|