Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

aspÊý×écookies²Ù×÷º¯Êý


±¾ÎĵĴ´ÔìÐÔÔÚÓÚcookies_to_array(c)   Ö±½Ó¼òµ¥¿ì½Ýת»¯×Ö·û´®ÎªÊý×éµÄ·½·¨
ÁíÍâ ±¾ÎIJÙ×÷µÄÊý×é ²»ÊÇ aspÆÕͨµÄ¶àάÊý×é ¶øÊǾâ³ÝÐ͵Ä
ÕâÖÖÊý×é ¸üÒײÙ×÷ ¸üÒ×ÔĶÁ ÐÐÁÐÇåÎú ºÜÏñÊý¾Ý¿âÖеıí
¿ÉÒÔÀà±ÈΪ datatable
class myarray
'±ØÐëΪ¾â³ÝÊý×éarray(array(1,2,3))
function array_to_cookies(a)
dim b(),i,j,u
u = ubound(a)
redim b(u)
for i=0 to u
array_rep a(i)
b(i)=join(a(i),",")
next
array_to_cookies=join(b,";")
end function
sub array_rep(a)
dim i
if isarray(a) then
for i=0 to ubound(a)
if instr(a(i),",")>0 then a(i)=replace(a(i),",","")
if instr(a(i),";")>0 then a(i)=replace(a(i),";","")
next
end if
end sub
function cookies_to_array(c)
c = "array(array("+replace(c,";","),array(")+"))"
execute "cookies_to_array="&c
end function
'ÒÔijÁÐΪÖ÷¼ü Ìí¼Ó»òÕ߸üРÐÐ
sub add_row(a,ai,columnum)
dim b(),i,j,u
u = ubound(a)
if columnum=-1 then'add
redim b(u+1)
else
redim b(u)
end if
j=0
for i=0 to u
if columnum>-1 then
if a(i)(columnum)<>ai(columnum) then
b(j)=a(i)
j = j+1
else
b(j)=ai
j = j+1
end if
else
b(j)=a(i)
j = j+1
end if
next
if columnum=-1 then
b(j)=ai
end if
a=b
end sub
function get_rownum(a,columnum,columv)
get_rownum=-1
dim i,j,u
u = ubound(a)
for i=0 to u
if a(i)(columnum)=columv then
get_rownum = i
exit function
end if
next
end function
'¸ù¾ÝÁкŠÁÐÖµ ɾ³ýijxieÐÐ Ö±½Ó¸Ä±äÔ­Êý×é
sub delete_row_by_colum(a,columnum,columv)
dim b(),i,j,u
u = ubound(a)
j =0
for i=0 to u
if a(i)(columnum)=columv then
j=j+1
end if
next
redim b(u-j)
j=0
for i=0 to u
if a(i)(columnum)<>columv then
b(j)=a(i)
j = j+1
end if
next
a=b
end sub
'¸ù¾ÝÐÐϱêɾ³ýÐÐ
sub delete_row(a,rownum)
dim b(),i,j,u
u = ubound(a)
j =0
redim b(u-1)


Ïà¹ØÎĵµ£º

¡¾ASP.net¼¼ÇÉ¡¿asp.netµ¯³ö´°¿Ú ·µ»ØÖµ

¸Õ¸Õ ¿´µ½Õâôһ¸öÎÊÌ⣬ÕâÀïÒ²×ö¸ö±ê¼Ç£ºhttp://topic.csdn.net/u/20080411/14/7b0f9da5-0413-4149-91e9-72c3df3018a3.html?seed=327251592
µÚÒ»ÖÖ·½Ê½£º
//ÔÚVisual Studio 2008Öе÷ÊÔͨ¹ý
testPop_Page.aspx:Ö÷Ò³ÃæASPX´úÂë
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
  ......

aspµÄÐĵÃ

    ASP²¿·Ö½²Êö£º   ¶ÔÓÚASPÀ´ËµÏàÐÅ´ó¼Ò¶¼²¢²»Ä°Éú£¬ÔÚÕâÀïÎҾͲ»ÀË·ÑÌ«¶àµÄʱ¼äÀ´½øÐвûÊöÁË¡£
       ÎÒÕâÀïÖ÷ÒªÊǼǼÁËÎÒÔÚ¶ÁASPʱµÄһЩÐĵúÍÎÒ×Ô¼ºÈÏΪӦ¸Ã×¢ÒâµÄµØ·½£¬Ï£ÍûÕâЩµãµãµÎµÎÄܹ»ÎªÄÇЩ³õѧµÄÅóÓÑÓÐÒ»¶¨µÄ°ïÖú£¬Í¬Ê±Ò²Ï£ÍûºÍÒѾ­ÓкÜÉî¾­ÑéºÍ ......

ASPÖеļǼ¼¯

eofÊÇaspÖÐrecordset¶ÔÏóÖ¸ÕëµÄÒ»ÖÖ¡£
rs.eof ·µ»Ø¼Ç¼ָÕëÊÇ·ñ³¬³öÊý¾Ý±íÄ©¶Ë£¬true±íʾÊÇ£¬falseΪ·ñ
rs¼Ç¼¼¯ÊÇÎÒÃǾ­³£»áÅöµ½µÄ,ÏÂÃæ¶ÔËüÖî¶àµÄÒƶ¯Ö¸Õë½øÐлã×Ü,ÈçÏÂ:
rs.movenext ½«¼Ç¼ָÕë´Óµ±Ç°µÄλÖÃÏòÏÂÒÆÒ»ÐÐ
rs.moveprevious ½«¼Ç¼ָÕë´Óµ±Ç°µÄλÖÃÏòÉÏÒÆÒ»ÐÐ
rs.movefirst ½«¼Ç¼ָÕëÒƵ½Êý¾Ý±íµÚÒ»ÐÐ ......

ASP×Ö·û´®º¯Êý´óÈ«

º¯Êý Óï·¨ ¹¦ÄÜ
Len Len(string|varname) ·µ»Ø×Ö·û´®ÄÚ×Ö·ûµÄÊýÄ¿£¬»òÊÇ´æ´¢Ò»±äÁ¿ËùÐèµÄ×Ö½ÚÊý¡£
Trim Trim(string) ½«×Ö·û´®Ç°ºóµÄ¿Õ¸ñÈ¥µô
Ltrim Ltrim(string) ½«×Ö·û´®Ç°ÃæµÄ¿Õ¸ñÈ¥µô
Rtrim Rtrim(string) ½«×Ö·û´®ºóÃæµÄ¿Õ¸ñÈ¥µô
Mid Mid(string,start,length) ´Óstring×Ö·û´®µÄstart×Ö·û¿ªÊ¼È¡µÃlength³¤¶ ......

aspʵÏÖÅúÁ¿Â¼ÈëÊý¾Ý

Çë¿´ÈçÏÂÔ´´úÂ룺
<%
'ÏòÊý¾Ý¿âдÈëÊý¾Ý
SUB writeData()
dim recCnt,i
dim fieldName1,fieldName2,fieldName3
dim conn
dim sqlStr,connStr
connStr="Provider=SQLOLEDB.1;Initial Catalog=myDatabase;Data Source=myhon;User Id=sa;PASSWORD="
set conn=Server.CreateObject("ADODB.Connection")
c ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ