Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. Will VB COM will do better than normal ASP ?

Will VB COM will do better than normal ASP ?

Scheduled Pinned Locked Moved Web Development
databaseperformancecomalgorithmstesting
5 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Rajkamal_dfine
    wrote on last edited by
    #1

    Hi All I have a web application which is developed by ASP and SQL I planed to optimize the asp code.... Can anybody suggest? Doing optimization on the asp file will boost the performance? Or creating VB COM will do better? Which one will be good? Note : I have done with a testing by creating COM that pulls around 100000 records from DB and display it in the Web page.... But I don't find any time difference when I ran the same with ASP file? Can anybody give me idea on this....? Regards N.Rajakumar B.E., Application Developer

    S J A 3 Replies Last reply
    0
    • R Rajkamal_dfine

      Hi All I have a web application which is developed by ASP and SQL I planed to optimize the asp code.... Can anybody suggest? Doing optimization on the asp file will boost the performance? Or creating VB COM will do better? Which one will be good? Note : I have done with a testing by creating COM that pulls around 100000 records from DB and display it in the Web page.... But I don't find any time difference when I ran the same with ASP file? Can anybody give me idea on this....? Regards N.Rajakumar B.E., Application Developer

      S Offline
      S Offline
      Shog9 0
      wrote on last edited by
      #2

      Rajkamal_dfine wrote:

      Can anybody give me idea on this....?

      You need to identify your bottlenecks. Saying, "it's slow" is meaningless - you need to identify what is slow. It may be that re-designed queries or a good caching strategy will do far more for your app than the fastest compiled code - there's just no way of knowing until you narrow down the scope. FWIW - while compiled VB can give a nice speed boost over interpreted ASP (VBS), keep in mind that ASP runs in the STA threading model, so you can find yourself just introducing another bottleneck. There are ways around this, and for some operations it makes sense even without them... it all depends on where your costs lie.

      ----

      It appears that everybody is under the impression that I approve of the documentation. You probably also blame Ken Burns for supporting slavery.

      --Raymond Chen on MSDN

      1 Reply Last reply
      0
      • R Rajkamal_dfine

        Hi All I have a web application which is developed by ASP and SQL I planed to optimize the asp code.... Can anybody suggest? Doing optimization on the asp file will boost the performance? Or creating VB COM will do better? Which one will be good? Note : I have done with a testing by creating COM that pulls around 100000 records from DB and display it in the Web page.... But I don't find any time difference when I ran the same with ASP file? Can anybody give me idea on this....? Regards N.Rajakumar B.E., Application Developer

        J Offline
        J Offline
        JoiSteingrims
        wrote on last edited by
        #3

        Hi As a short answer. My experience is that when I took out some com objects out of an application and moved its logic, unchanged, in the asp code the performance was much better. Also if you have typical asp code you should take all extra <% and %> tags out of your code to boost up your performance. Typical asp source code involves html code and logic, separate it and use Response.write "Name:"& rs("sName") instead of %> Name: <%= rs("sName")%> ...<% syntax. -Joi

        G 1 Reply Last reply
        0
        • R Rajkamal_dfine

          Hi All I have a web application which is developed by ASP and SQL I planed to optimize the asp code.... Can anybody suggest? Doing optimization on the asp file will boost the performance? Or creating VB COM will do better? Which one will be good? Note : I have done with a testing by creating COM that pulls around 100000 records from DB and display it in the Web page.... But I don't find any time difference when I ran the same with ASP file? Can anybody give me idea on this....? Regards N.Rajakumar B.E., Application Developer

          A Offline
          A Offline
          andyharman
          wrote on last edited by
          #4

          The ADO ResultSet object has a GetString method that can render the entire resultset as a single string: strData = objRS.GetString( , , "#<#/td#>##<#td#>#", _ "#<#/td#>##<#/tr#>##<#tr#>##<#td nowrap#>#", "#&#nbsp;") strData = Replace(Replace(Replace(strData, "#&#", Chr(1)), "&", "&"), Chr(1), "&") strData = Replace(Replace(Replace(strData, "#<#", Chr(1)), "<", "<"), Chr(1), "<") strData = Replace(Replace(Replace(strData, "#>#", Chr(1)), ">", ">"), Chr(1), ">") strData = "" & Replace(Left(strData, Len(strData) - 15), "", "" & vbCRLF) Call Response.Write(strData) Most of the code is used to add table tags around each of the cells. We use similar code to produce quite large MS-Excel reports. Regards Andy

          1 Reply Last reply
          0
          • J JoiSteingrims

            Hi As a short answer. My experience is that when I took out some com objects out of an application and moved its logic, unchanged, in the asp code the performance was much better. Also if you have typical asp code you should take all extra <% and %> tags out of your code to boost up your performance. Typical asp source code involves html code and logic, separate it and use Response.write "Name:"& rs("sName") instead of %> Name: <%= rs("sName")%> ...<% syntax. -Joi

            G Offline
            G Offline
            Guffa
            wrote on last edited by
            #5

            JoiSteingrims wrote:

            Also if you have typical asp code you should take all extra <% and %> tags out of your code to boost up your performance.

            The important thing is to make sure that response buffering is enabled. With buffering turned off, you take a performance hit every time you enter and leave a <% %> tag, but with buffering enabled you don't. Actually the testing I have done shows that using <%= %> is slightly faster than concatenating strings with the & operator. The difference is quite small, though, so use the one that gives the nicest code. I always put Response.Buffer = True at the top of every page. It takes a fraction of a millisecond to run each time, but if someone disables buffering on the server, it keeps your pages from suddenly being incredibly slow.

            --- single minded; short sighted; long gone;

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups