View Single Post
  #1 (permalink)  
Old February 4th, 2004, 11:32 PM
kondin kondin is offline
Registered User
 
Join Date: Feb 2004
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Invalid path for MapPath

Problem with ThePhileVB running on Win2k.At first time I think the same problem with topic ID=640. Then I try to follow that forum but problem still persist.

Error Message
Invalid path for MapPath 'C:/wrox/ThePhileVB/Config/Polls.Config'. A virtual path is expected.

Error Stack:
System.ArgumentException: Invalid path for MapPath 'C:/wrox/ThePhileVB/Config/Polls.Config'. A virtual path is expected.
   at System.Web.HttpRequest.MapPath(String virtualPath, String baseVirtualDir, Boolean allowCrossAppMapping)
   at System.Web.HttpServerUtility.MapPath(String path)
   at Wrox.WebModules.Polls.Configuration.ModuleConfig.G etSettings() in C:\wrox\ThePhileVB\WebModules\Polls\Polls.Configur ation\ModuleConfig.vb:line 31
   at Wrox.WebModules.Polls.Business.Question.GetCurrent Id() in C:\wrox\ThePhileVB\WebModules\Polls\Polls.Business \Question.vb:line 224
   at Wrox.WebModules.Polls.Web.Controls.User.Poll.DataB ind() in C:\wrox\ThePhileVB\WebModules\Polls\Poll.ascx.vb:l ine 260
   at Wrox.WebModules.Polls.Web.Controls.User.Poll.Page_ Load(Object sender, EventArgs e) in C:\wrox\ThePhileVB\WebModules\Polls\Poll.ascx.vb:l ine 62
   at System.Web.UI.Control.OnLoad(EventArgs e)
   at System.Web.UI.Control.LoadRecursive()
   at System.Web.UI.Control.LoadRecursive()
   at System.Web.UI.Control.LoadRecursive()
   at System.Web.UI.Page.ProcessRequestMain()

I try to modify FileStream constructors in the ModuleConfig.vb in all config file (follow FAQ that sent with download source code.) and rebuild solution but can't solve problem.
Dim fs As New FileStream(fileName, FileMode.Open, FileAccess.Read)