asp-classic

COM Interop .Net - Out of Memory/BUFFER OVERFLOW error when executing asm method

This is a strange one. For a long time now an application I develop on has been using com interop to use .Net types in an Classic ASP application. I fired this application up again today to look at some issue with it got an Out Of Memory error when accessing a method on one of these objects. Fine - I thought, I'll just unregister the ...

Option Compare Text in Classic ASP

This should be a TOTAL no-brainer, but I haven't really written any classic ASP code in like 10 years and just cannot remember how to do this, and can't find it on google. All I'm looking to do is to set a Classic ASP page to use Option Compare Text, but I cannot remember the syntax for this. I've tried all of the following, as the fir...

paging on SQL Server database

It is very simple to do paging on access database (using absolute and pagesize) but I heard its hard to do paging on SQL Server database. How do I do I add simple paging to the following codes. <% SQL = "SELECT I.IMAGESID, I.IMAGESNAME, I.IMAGESSMURL" SQL = SQL & " FROM IMAGES I" Set objImages = objConn.Execute(SQL) %> ...

SQL Server paging error

In my recent question, I asked for paging methods in SQL Server. Reading an article someone posted there, I came up with the following code. Everything seems correct to me but I receive the following error: The ORDER BY clause is invalid in views, inline functions, derived tables, subqueries, and common table expressions, unless TOP or ...

Error Type: Microsoft VBScript runtime (0x800A0046) Permission denied

I am getting this error when i try to access an asp website which has been hosted in IIS 5. Error Type: Microsoft VBScript runtime (0x800A0046) Permission denied /Site/Initial.asp, line 164 Please let me know what could be is issue??? ...

Classic ASP Request.ServerVariables("LOGON_USER") returning wrong username

Hi, Classic ASP Request.ServerVariables("LOGON_USER") is returning wrong username. Here is the scenario: I have two accounts on the domain, one for administration and one for normal use. The admin account is set as admin (in the Administrators group) on the server where the ASP script is running on. Server is Windows 2003 running IIS 6...

How can I compare two dates in vbscript/ASP?

Using ASP classic, I need to somehow compare two dates with each other. How can I do this? ...

Localizing Classic ASP

HOw to localize classic asp? I got something from below link http://networkprogramming.spaces.live.com/blog/cns!D79966C0BAAE2C7D!379.entry but when i do that, i am getting error. Error Type: Microsoft VBScript runtime (0x800A01A8) Object required: 'xmlResx' /MySite/default.asp, line 14 ...

How can I get the previous page from history in classic ASP?

Is there a way I can get the previous page the user was at in classic ASP? I am looking for the equivalent of history.go(-1) in JavaScript. ...

Google Calendar integration with Classic ASP

Hiya, I need to integrate a google calendar to my ASP website booking system. I've tried to write events to the calendar from my application using the javascript API, but it's failing when the client is not logged in to Gmail - obviously a problem if my customers aren't logged in my Gmail account. Therefore I assume it's not possible ...

Where to store connection string for classic ASP ?

In ASP.NET i can store connection string in the web.config, like wise i need to store connection string or some configuration value in some file for classic ASP. How can i do this? In order to achieve this do i need to use XML File and store the connection string in this? What is the best practice??? ...

alternative to ancestor-or-self ( or select all nodes in the tree with a specific child node)

I am trying to identify all the nodes in a tree that lead to a specific node. I am trying to accomplish this through either MSSQL XML (2005) or by the Microsoft.XMLDOM in ASP classic. I know the logic with XPATH but SQL Server does not support the ancestor-or-self axis and XMLDOM seems to choke on the :: notation.. The xpath that work...

How can I use a SqlConnection (ADO.Net) to connect to an ADO recordset?

I am having tough time since 2 days, and not able to figure out what should i do with my implementation. I am not sure if this could be really workable. Please help me on this. Below is my scenario: I have a .Net Dll which has a method that returns a SqlConnection object after opening it. Below is the function (similar to which i am u...

How to trigger logon button when user presses enter on classic asp page with two buttons?

Hi, I have a classic asp page with two buttons, one for LOGON and another for REGISTER. I have named both buttons as "bsubmit" so I can query the value to determine which button is pressed. That works fine.. But when the user presses ENTER, I want the LOGON button to trigger instead of the REGISTER button. This page has a hidden input...

Endless runtime for a script that sometimes works

After I execute this code asp scripts quite working. <!-- #include file="Connection.asp" --> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt; <% function Page() { var db = new DBConnection; this.DAL = db.retriveDAL("Content"); var url = new String(Request.ServerV...

Classical ASP Scripting Timeout

Is it possible to catch a classical ASP Scripting Timeout and redirect to a proper self defined error page, to avoid that the user sees the runtime error page ? ...

How can I put a small panel from my website onto someone else's website but still handle the submit?

On a classic ASP website I'm maintaining, on our landing page we have a small panel that our visitors use to enter their phone number as an identifier, then they proceed into the site. We now have an opportunity to place this login panel on some other websites, pretty much like an ad, the idea being that not only would clicking it get t...

Where can I find an editor for "classic" ASP code?

From where can I get a classic asp editor? ...

Does setting an ADO Command's ActiveConnection = Nothing close the underlying SQL Connection?

I have a customer who's Classic ASP application is generating ASP_0147 errors. The first thing I'm checking is that they're closing and releasing SQL/ADO resources timeously. Their code has the following pattern: Function GetXXXXRecordSet() Set objConn = Server.CreateObject("ADODB.Connection") With objConn .CursorLocation = 3 ...

How to tell if a call to SQL Execute() using ADO fails in classic ASP

I have the following shortened classic ASP code that makes a SQL insert call... cmd.CommandText = "insert into MyTable values(blah, blah, blah)" cmd.CommandType = adCmdText Set rs = cmd.Execute() Using the recordset that Execute() returns how can I tell whether the insertion was successful or not? ...