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

ASPÖÐSplitº¯ÊýµÄʵÀý

´ó¼ÒÓÐÅöµ½¹ýÒªÏëÈ¡Ò»×Ö·û´®ÀïµÄijЩֵ¶øÎÞ´ÓÏÂÊÖ£¿ÓÐûÓоõµÃ¿´Êé»ò½Ì²Ä¶ÔsplitµÄд·¨ºýÀïºýÍ¿……Èç¹ûÓдËÒÉÎʵĻ°£¬Çë¿´ÏÂÃæÎÒ¶ÔÀý×ӵĽâÊÍ£¬ÏàÐÅÄú»á¶ÔÕâ¸öÓÐÒ»¶¨µÄÁ˽⡣
ÎÒÏȽéÉÜÒ»ÏÂSplitº¯ÊýµÄÓ÷¨:
·µ»ØÖµÊý×é = Split("×Ö·û´®","·Ö¸î·û")
¼ÙÉè±äÁ¿strURL±£´æ×ÅURLÖµ£¬ÈçstrURL = "ftp://username:password@server"£¬ÕâÊÇÎÒÃÇÔڣɣÅÖеǼµ½FTPÉÏʱµÄ£Õ£Ò£ÌÐÎʽ£¬Èç¹ûÎÒÃÇÏë°ÑÆäÖеÄusernameºÍpasswordÈ¡³öÀ´µÄ»°£¬¸ÃÔõô°ìÄØ£¿µ±È»½â¾öµÄ·½·¨ÓÐÐí¶à£¬ÔÚÕâÀïÎÒÃÇÖ»½éÉÜÓÃSplitÀ´½â¾öµÄ·½·¨¡£Ê×ÏÈ£¬ÎÒÃÇÕÒ³ö·Ö¸î·û¡£ÎÒÃÇ·¢ÏÖÔÚÕâ¸ö×Ö·û´®ÖУ¬usernameºÍpasswordÖ®¼äÓиöðºÅ°ÑËüÃǸô¿ªÁË£¬ËùÒÔÎÒÃǾͰÑÕâ¸öðºÅ×÷ΪSplitº¯ÊýµÄ"·Ö¸î·û"À´·Ö¸îÕû¸ö×Ö·û´®£¬×îºó´ïµ½È¡usernameºÍpasswordµÄÄ¿µÄ¡£´úÂëÈçÏ£º
strURL = "ftp://username:password@server"
aryReturn = Split(strURL,":")
ÕâÑùÎÒÃǾͰÑ×Ö·û´®ÓÃðºÅ·Ö¸î¿ªÁË£¬·Ö¸îºóµÄ½á¹û±£´æÔÚaryReturnÖУ¨aryReturnÊÇÒ»¸öÊý×飩¡£
ÏÂÃæÎÒÃǾÍÀ´¿´¿´Õâ¸ö×îÖյĽá¹û°É£¬ÒòΪSplitº¯Êý×îÖÕ·µ»ØµÄÊÇÒ»¸öÊý×飬ËùÒÔÎÒÃÇÖ÷Òª¾ÍÊÇÏÔʾÊý×éÖеÄÔªËØÁË£¬¾ÍÒªÉæ¼°µ½Ò»Ð©¸úÊý×éÓйصĺ¯Êý:IsArray()ÅжÏÊÇ·ñÊý×éµÄº¯Êý,LBound()È¡Êý×éµÄϱê,UBound()È¡Êý×éµÄÉϱꡣ
Response.Write("·µ»ØÖµÊÇ·ñΪÊý×é:" & IsArray(aryReturn) & "<br>")
For i = LBound(aryReturn) To UBound(aryReturn)
Response.Write("·µ»ØÖµÊý×éÖеÄÔªËØ[" & i & "]£º" & Right(aryReturn(i),Len(aryReturn(i))-2) & "<br>")
Next

ͨ¹ýÉÏÃæµÄ´úÂ룬ÎÒÃÇ¿´µ½×Ö·û´®±»·Ö¸î³ÉÈý¸ö²¿·Ö£¬¼´£º"ftp"¡¢"//username"¡¢"password@server"¡£ÎÒÃÇҪȡusernameºÍpasswordÐèÒª½øÒ»²½µÄ´¦Àí£¬ÎҾͲ»¶à˵ÁË£¬Ö±½Ó¸ø³ö´úÂë¡£
È¡usernameµÄ´úÂ룺
strUsername = Right(aryReturn(1),Len(aryReturn(1))-2)
È¡passwordµÄ´úÂ룺
'È¡passwordÎÒÃÇÓÖÓõ½Splitº¯ÊýÁË£¬²»¹ýÕâ»ØµÄ·Ö¸î·ûÊÇ"@"
aryTemp = Split(aryReturn(2),"@")
strPassword = aryTemp(0)
'ÎÒÃÇ¿ÉÒÔ˳±ãÈ¡³öserver
strServer = aryTemp(1)
'·Ö¸î·û¿ÉÒÔÊÇÒ»¸ö×Ö·û£¬Ò²¿ÉÒÔÊÇÒ»¸ö×Ö·û´®¡£È磺
aryReturn = Split("ftp://username:password@server,"//")
×¢Ò⣺
¡¡¡¡1.Ò»°ãÀ´Ëµ£¬ASPÖпÉÒÔ²»ÉùÃ÷±äÁ¿£¬Ê¹ÓÃSplitº¯Êýʱ£¬Èç¹ûÒªÉùÃ÷·µ»ØÖµµÄ±äÁ¿µÄ»°£¬Ö»ÄÜÓÃDim£¬¶ø²»ÄÜÓÃRedim¡£ËäȻ˵Æä·µ»ØÊÇÒ»¸öÊý×飬Ó


Ïà¹ØÎĵµ£º

2¡¢´¿ASP´úÂëÉú³Éͼ±íº¯Êý——Öùͼ

2¡¢´¿ASP´úÂëÉú³Éͼ±íº¯Êý——Öùͼ
<%
dim total(12,2)
total(1,1)=56
total(2,1)=7
total(3,1)=-7
total(4,1)=0
total(5,1)=16
total(6,1)=10
total(7,1)=14
total(8,1)=7
total(9,1)=9
total(10,1)=7
total(11,1)=11
total(12,1)=14
total(1,2)="µØÀí"
total(2,2)="»¯Ñ§"
total(3,2)="ÀúÊ· ......

3¡¢´¿ASP´úÂëÉú³Éͼ±íº¯Êý——ÕÛÏßͼ

3¡¢´¿ASP´úÂëÉú³Éͼ±íº¯Êý——ÕÛÏßͼ
<%dim total(7,3)
total(1,0)="Öйú¾­Óª±¨"
total(2,0)="ÕÐƸÍø"
total(3,0)="51Job"
total(4,0)="ÐÂÃñÍí±¨"
total(5,0)="ÐÂÎÅÍí±¨"
total(6,0)="ÄÏ·½ÖÜÄ©"
total(7,0)="Ñò³ÇÍí±¨"
total(0,1)="#FF0000,1.5,1,2,¹«Ë¾1"'²ÎÊý1ÏßÌõµÄÑÕÉ«£¬²ÎÊý2ÏßÌõµÄ¿í¶È£¬²ÎÊý3Ï ......

asp µ¼Èëµ¼³öEXCEL

Ò»¡¢asp.netÖе¼³öExeclµÄ·½·¨£º
ÔÚasp.netÖе¼³öExeclÓÐÁ½ÖÖ·½·¨£¬Ò»ÖÖÊǽ«µ¼³öµÄÎļþ´æ·ÅÔÚ·þÎñÆ÷ij¸öÎļþ¼ÐÏÂÃ棬Ȼºó½«ÎļþµØÖ·Êä³öÔÚä¯ÀÀÆ÷ÉÏ£»Ò»ÖÖÊǽ«ÎļþÖ±½Ó½«ÎļþÊä³öÁ÷д¸øä¯ÀÀÆ÷¡£ÔÚResponseÊä³öʱ£¬t·Ö¸ôµÄÊý¾Ý£¬µ¼³öexeclʱ£¬µÈ¼ÛÓÚ·ÖÁУ¬nµÈ¼ÛÓÚ»»ÐС£
1¡¢½«Õû¸öhtmlÈ«²¿Êä³öexecl
´Ë·¨½«htmlÖÐËùÓеÄÄÚ ......

asp·ÖÒ³´úÂë

 <%'¿ªÊ¼·ÖÒ³
    Const MaxPerPage=25
       dim totalPut  
       dim CurrentPage
       dim TotalPages
       dim j
     ......

aspÎļþ¶Áд

<%
Set fso = CreateObject("Scripting.FileSystemObject")
Set fldr = fso.GetFolder("c:\Program Files")
Response.Write "¸¸Îļþ¼ÐÃû×ÖÊÇ£º" & fldr & "<br>"
If fldr.IsRootFolder = True Then
   Response.Write "¸ÃÎļþ¼ÐÊÇÒ»¸ùÎļþ¼Ð" & "<br>"
Else
   Resp ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ