Connecting to a Visual Foxpro (DBF) table.
-
I have put my web-site together and everything works fine when working on my computer. I have one page that works with a Visual FoxPro table (dbf). In my web.config file, the only way to get it to find the table is to put in the complete path to the file. The file on my site is located in the App_Data folder off of the root. Here is the connection string that works on my local computer when running under Visual Web Developer: How can I get my ASP.Net application to find this table on my web-site? Should I use information in the web.config file or is there another approach that will work? Any help would be much appreciated. Thanks! Dave :-)
-
I have put my web-site together and everything works fine when working on my computer. I have one page that works with a Visual FoxPro table (dbf). In my web.config file, the only way to get it to find the table is to put in the complete path to the file. The file on my site is located in the App_Data folder off of the root. Here is the connection string that works on my local computer when running under Visual Web Developer: How can I get my ASP.Net application to find this table on my web-site? Should I use information in the web.config file or is there another approach that will work? Any help would be much appreciated. Thanks! Dave :-)
Hello, You can use Server.MapPath("App_Data\ADASurvey.dbf"); This method maps the specified relative or virtual path to the physical directory on the server.
-
Hello, You can use Server.MapPath("App_Data\ADASurvey.dbf"); This method maps the specified relative or virtual path to the physical directory on the server.
-
Ilya, Can I use this in my web.config file or do I need to do something in my page load event? Dave :-)
You should manage this in load event.