asp-classic

vbscript / Classic ASP - Is there any way to get your own file name programmatically?

I was just reviewing some old code and found the following (inside foo.asp): Const ASP_FILENAME = "foo.asp" ' TODO: Update this to the name of this file (if changed) The variable is only used for logging errors. (ie. "Error in foo.asp - Could not create xxxxx object.") Is there any way to avoid this? Thanks! ...

How to do effective paging in Classic ASP?

I'm trying to page a table, and while I have paging already working, it displays every page in a single line along with Previous/Next links, causing the HTML page to break if there are a lot of results (which often there are). What I'd like to do is display the pages in batches of 10, e.g. 1...10, if you're on page 10 and click "Next" t...

Classic ASP/IIS6: How to search the server’s mime map?

This is the same question as this but I'm looking for a classic ASP solution. I have a third party control to provide secure downloads but it expects you to provide the response.contenttype value. I'm trying to have the browser prompt with the following: Response.AddHeader "Content-Disposition", "attachment;filename=""" & strFileName &...

Calling VBScript from JavaScript or vice versa?

Is it possible to call a VBScript function from a JavaScript call, or alternately call JavaScript from a VBScript call? ...

ob_get_contents equivalent in asp

Working on an old site in asp classic. I want to write a function that returns some html. Right now I'm reduced to writing everything in a string. The downsides are: I have to escape quotes There is no code completion on the tags nor attributes In php I know how to get the contents of the output buffer with ob_get_contents. Is ther...

How do you get the name of the current virtual directory using ASP Classic?

How do you get the name of the current virtual directory using ASP Classic? In ASP.NET you can use Request.ApplicationPath() to find this. For example, let's say you have a URL like this: http://localhost/virtual_directory/subdirectory/file.asp In ASP.NET, Request.ApplicationPath() would return /virtual_directory ...

Is try-catch like error handling possible in asp classic

What options are there in asp for error handling. For example: I'm using the Mail.SendMail function but when switching on the testing server it doesn't work, which is normal. I want to test if mailing is possible, if not then continu and/or show a message. Any ideas? ...

Route files with vbscript from a .net handler back to asp.dll

We are migrating from asp classic to .net. Unfortunately they named all of the .asp files as .aspx so that they wouldn't lose page rank when they moved to .net. This means that IIS maps all .aspx files to asp.dll. After changing the mapping back I was going to try have a handler grab the request then check if there is any vbscript in th...

Choices: Migrating from Classic ASP to .NET or Migrate to Open-Source Platform

My organization has a lot of legacy ASP software on its hands. Since our perception is that Microsoft has shown a distinct lack of support for its older products, we need to figure out what to migrate to next. If we migrate to ASP.NET from Classic ASP, It feels like that'd be a 'complete rewrite' "migration". Since that is probably th...

why do you think microsoft hasn't implemented asp-classic as another language in .net

a couple of days ago I had this idea, why not implementing asp-classic as another language in .net... it would have helped lots of people to migrate to the new platform... I mean there's IronRuby, IronPython, etc... It sounded to me like a great idea... but, come on, I'm no genius, there must be some reason why they haven't done so......

is it possible to issue dynamic include in asp-classic?

I mean, like php'h include... something like my_file_to_be_included = "include_me.asp" -- > for what I've seen so far, there are a couple of alternatives, but every one of them has some sort of shortcoming... what I'm trying to figure out is how to make a flexible template system... without having to statically include the whole t...

Classic ASP: Attached Debugger

Is it possible to step though Classic ASP VB code without Visual interdev or other such IDEs? I'm currently using Notepad++ to maintain a old ASP project and the ability to step though code at certain types would be helpful. Thank You, Frank ...

Can I replace content in an ASP (Classic) include?

Say I have "default" content on the left side of my application, which is included in a header page: a search box and a login box. If the user is on the search page, I want to also add a list of search filters (e.g. brand, price) to the left side of the page; in this case the left side needs to access the parameters given to the search ...

Can a Classic ASP application be secured using HTTPModules?

I have a classic ASP application currently secured using ASP.NET Forms Authentication running on IIS 6, the problem is our purposes require this application implement a Single-Signon security model using Entrust TruePass which uses Client Certificates I believe. Can this be implemented using ASP.NET Http Modules or do I have to write an ...

Classic ASP Server.MapPath() doesn't work as expected in global.asa

In Classic ASP, Server.MapPath() doesn't always work properly in the Application_OnStart event within global.asa. I have an ASP page at "\testfolder\test.asp" within a virtual root, I have an XSLT file at "\xsl\transform.xsl". My virtual root is located in "c:\inetpub\wwwroot\testapp\". I use MapPath within the ASP page to get the full ...

sharing asp session over virtual directory

In IIS I have asp (classic) site. In that site there is virtual directory. Is there any way to share session between those two web applications? tnx ...

Using CreateObject("Excel.Application") - issues with unsigned control

Hi all We have a legacy ASP page that writes content to an excel file by generating client-side VB script based on data from the database. It uses set app = CreateObject("Excel.Application") to initialize Excel. The problem is that this is an "unsigned activex control", and some clients are now saying they wont change their IE settings...

What do you use to edit and develop Classic ASP

What editors and tools do you use to develop in Classic ASP. I am currently use TextPad but its not great so I am looking for alternatives. The problems that i am having with TextPad is that it seems to try to do syntax highlighting but it gets messed up which makes it hard to read. I feel like using a better tool could be more product...

How can I migrate email functionality from ASP Classic to ASP.NET?

I previously used CDO.Message and CDO.Configuration in ASP Classic to create HTML emails which was VERY simple to do. In .NET, it appears that you have to give the System.Net.Mail.Message object an HTML string for the content and then somehow embed the required images. Is there an easy way to do this in .NET? I'm pretty new to .NET MVC a...

Classic ASP: How to list activated sessions?

Is there someway to get a list of activated sessions in classic ASP? I want to limit the number of simultaneus activated sessions. ...