当前位置: 首页 > 图文教程 > 网络编程 > ASP > 不用组件来实现StrCat函数的功能

ASP
构造ConnectionString的方法
在asp中如何创建动态表--调用如下sp_execute
Jmail中避过smtp验证的一法
取出所有的传递参数短方法
提高ASP性能的最佳选择(二)
提高ASP性能的最佳选择(三)
提高ASP性能的最佳选择(续一)
提高ASP性能的最佳选择(续二)
提高ASP性能的最佳选择(续三)
提高ASP性能的最佳选择(续四)
一种效率极高的分类算法
不刷新页面的情况下调用远程ASP
谈两种数据库内容HTML格式的输出方法
提高ASP页面的执行效率(上)
提高ASP页面的执行效率(中)
提高ASP页面的执行效率(下)
ASP.Net中程序构架与程序代码的分离
如何用checkbox做多选删除
判断输入是否为中文的函数
将半角转换为中文的函数

ASP 中的 不用组件来实现StrCat函数的功能


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-03   浏览: 42 ::
收藏到网摘: n/a

  really really slow by nature. This sample code uses classes to speed up the process by ten times. Someone recentally came up with a DLL to do this but not all of us can install a DLL on our ISP's web servers so I wrote this easy to use VB Class for handling string concatenation.

code:
Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!


Terms of Agreement:   
By using this code, you agree to the following terms...   
1) You may use this code in your own programs (and may compile it into a program and distribute it in compiled format for langauges that allow it) freely and with no charge.   
2) You MAY NOT redistribute this code (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
3) You may link to this code from another website, but ONLY if it is not wrapped in a frame.
4) You will abide by any additional copyright restrictions which the author may have placed in the code or code's description.  


    '**************************************
    ' Name: StrCat - Non DLL version
    ' Description:ASP's ability to concatena
    '     ting many strings together is really rea
    '     lly slow by nature. This sample code use
    '     s classes to speed up the process by ten
    '     times. Someone recentally came up with a
    '     DLL to do this but not all of us can ins
    '     tall a DLL on our ISP's web servers so I
    '     wrote this easy to use VB Class for hand
    '     ling string concatenation.
    ' By: Kevin Pirkl
    '
    ' Inputs:Public Property Length - To res
    '     ize the string length. To use it a secon
    '     d time on another string just set the .L
    '     ength property to another value or just
    '     dereference the object and recreate it.
    Public Method Add - too add data to the concatenated string.
    '
    ' Assumes:Didnt do much testing except u
    '     sing it to add together a string of 100,
    '     000 characters and it took about 7 secon
    '     ds which is not bad. If you need to add
    '     together more than that dont use this. I
    '     f your catting char strings like "<TR
    '     >" + whatever then it should be ok.
    '
    'This code is copyrighted and has    ' limited warranties.Please see http://w
    '     ww.Planet-Source-Code.com/xq/ASP/txtCode
    '     Id.6342/lngWId.4/qx/vb/scripts/ShowCode.
    '     htm    'for details.    '**************************************
    
    Set X = New strCat' Create an instance of strCat