Hi All,
I have come across a problem with a routine we use that "installs" our
database.
Basically the procedure uses the output from gendbc to modify or set up the
database. In broad terms the procedure:-
1. Determines where the database is located (Held in the registry).
2. Backs up the database to a backup folder
3. Destroys the database
4. Creates a new empty database
5. Appends the data from the backup into the new database.
The problems I have found appear to originate with Vista's file system
security enhancements. The main issue is with:-
if File(thisform.db_location+"\Mydb.dbc") && Under vista is the database
is on my server. This says the file does not exist
&& A database exists so this is an upgrade
Back up data etc
else
&& No database so just create an empty one
endif
I have changed all the permissions on the folder on the server etc but to no
avail. The exact same code works under xp.
Also, the code will work under vista if run from the ide.
In an attempt to solve the problem I have used the drivetype command to
determine if the drive is local or a network share. This command
DRIVETYPE(JUSTDRIVE(FULLPATH(thisform.DB_LOCATION)))
returns
1 (unknown drive type) under vista
and 4 (network share) under XP
Furthermore, the procedure works fine in Vista if the database is located on
a local drive (IDE & compiled)
The server runs Windows 2003 SBS.
Any help greatly appreciated
Rgds
Jan B