Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 30th, 2004, 02:05 PM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default Server.MapPath() error 'ASP 0173 : 80004005'

Hi, I've read thru a few of the threads about this topic and haven't found anything quite like I'm experiencing. I'm not even sure if this is possible:

Can I do the following:

Set objFolder = objFSO.GetFolder(Server.MapPath( "http://www.mycompany.ca/folder/subfolder/"))

They both live on the same server (as the page requesting the content of that folder). However it is a private site and therefore requires an absolute path, or does it?
 
Old August 30th, 2004, 02:43 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi there,

You cannot use the MapPath method to get the location of another site. All you can pass to MapPath is a virtual path within your application. Something like "MyFolder/MyFile.asp" or "/MyFolder/MyFile".

Passing an http address to this method will not work.

Cheers,

Imar
 
Old August 31st, 2004, 12:39 PM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you Imar, IS there a method to doing this?
 
Old September 1st, 2004, 03:54 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

AFAIK, there isn't. If you know the structure of the other site, you could use Server.MapPath to get the path of the current site, and then use replace to change the staring path of the file.

Pretty messy, but it might work.

What are your requirements for this functionality? What are you using it for?

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Error Type:Server.MapPath(), ASP 0171 (0x80004005) phantom3008 ASP.NET 1.0 and 1.1 Basics 2 April 26th, 2007 02:28 PM
Server.mappath and concatenation MArk_dB Classic ASP Basics 5 March 6th, 2007 03:48 PM
Server.MapPath johanyu ASP.NET 1.0 and 1.1 Basics 0 October 19th, 2004 12:42 AM
Server.MapPath stu9820 Classic ASP Basics 1 January 9th, 2004 04:16 PM
server.mappath kyootepuffy Classic ASP Databases 1 September 5th, 2003 04:17 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.