Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » DBISAM Technical Support » Support Forums » DBISAM General » View Thread |
Messages 1 to 4 of 4 total |
Database Directory path when running from ISAPI |
Mon, Jul 3 2006 4:51 AM | Permanent Link |
"Steve McGrath" | Hi,
I'm using an ISAPI dll to access a DBISAM database. The DBISAM files are in a subfolder under the dll called '/data'. I know this is more of a general ISAPI question but who do I code the data folder without having to hard code the entire path. If I use the following code: DBISAMDatabase1.Directory:='.\data\'; it will fail when run under IIS. However it works fine when debugging under a simple web server standalone exe (wwwserver.exe availbale from kbmMW). Using IIS I have to hard code the entire path to get it to correctly point at the database folder: DBISAMDatabase1.Directory:='d\inetpub\scripts\data'; Has anyone been able to workaround this when using IIS? Thanks, Steve |
Mon, Jul 3 2006 5:18 AM | Permanent Link |
"Ralf Mimoun" | Steve McGrath wrote:
> Hi, > > I'm using an ISAPI dll to access a DBISAM database. The DBISAM files > are in a subfolder under the dll called '/data'. I know this is more > of a general ISAPI question but who do I code the data folder without > having to hard code the entire path. I'd use the registry. Ralf |
Mon, Jul 3 2006 5:36 AM | Permanent Link |
"Robert Cram" | Hi Steve,
You can use the "GetModuleFileName" function in your code (using hInstance), extract the path, and add the "data" directory. It works for me. HTH, Robert. Steve McGrath wrote: > Hi, > > I'm using an ISAPI dll to access a DBISAM database. The DBISAM files > are in a subfolder under the dll called '/data'. I know this is more > of a general ISAPI question but who do I code the data folder without > having to hard code the entire path. If I use the following code: > > DBISAMDatabase1.Directory:='.\data\'; > > it will fail when run under IIS. However it works fine when debugging > under a simple web server standalone exe (wwwserver.exe availbale > from kbmMW). > > Using IIS I have to hard code the entire path to get it to correctly > point at the database folder: > > DBISAMDatabase1.Directory:='d\inetpub\scripts\data'; > > Has anyone been able to workaround this when using IIS? > > Thanks, > Steve -- |
Mon, Jul 3 2006 7:07 AM | Permanent Link |
"Steve McGrath" | Robert,
This works a treat, Thanks, Steve "Robert Cram" <rcram@knoware.nl> wrote in message news:xn0eoa91e2opkze000@news.elevatesoft.com... > Hi Steve, > > You can use the "GetModuleFileName" function in your code (using > hInstance), extract the path, and add the "data" directory. It works > for me. > > HTH, > Robert. |
This web page was last updated on Tuesday, April 23, 2024 at 08:10 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |