Hi!
As far as I know, it is not possible to do.
You can try though create ASP objects that would mimic something like System.IO.File.Exists(), though it is a bit of work that is better to spend on complete ASP converting to ASPX.
Why you would like to have the code run both as ASP and as ASPX?
>I am looking for an alternative of this ASP code which would make it run ok either inside an ASP page or inside an ASPX page.
>
>
>Set loFSO=CreateObject("Scripting.FileSystemObject")
>lcFile=Server.MapPath(lcFileToLookFor)
>If Not loFSO.FileExists(lcFile) Then
> lnExistFrench=0
>End If
>
>
>The problem is when being run inside an ASPX page, the Set of the first line has to be removed. So, I need some ASP code that would do the equivalent which would fit in both pages.
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.comICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs
It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.