Article View: borland.public.vdbase.data.sql
Article #194Re: creating tables
From: pces
Date: Wed, 06 Jan 1999 00:00
Date: Wed, 06 Jan 1999 00:00
34 lines
1678 bytes
1678 bytes
> dbfPathAndName = set("directory") + "\TMPX.DBF"
>
That's very short and sweet...
> The following courtesy of Romain (of course):
>
> FUNCTION GetDatabaseDir(oDatabase)
> if type("GetAliasPath") # "FP"
> extern cint GetAliasPath(cHandle,cString,;
> cString,cString);
> IDAPI32 from "DbiFormFullName"
> endif
> cRet=space(261)
> if ( GetAliasPath(oDatabase.handle,"YabbaDabbaDoo","",cRet ) == 0 )
> cRet=cRet.left(cRet.lefttrim().lastindexof("\"))
> else
> cRet=""
> endif
> RETURN cRet
>
Thanks Gary! Thanks Romain! I don't think I'd EVER think of
somethinglike the above code. It's so complicated, especially with the
extern function.
Edmund
PS: I solved the temporary database file in the wrong directory problem.
I just
had to SET DATABASE TO before the Create table and everything worked!
Of course, I had to get rid of the Query and Database objects as I'd
figured
having them on the form might give me instability errors.
Technical Details
Message-ID:
<3692C120.3772F0FD@netfront.net>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<36905D71.848AE379@netfront.net> <36907CE3.6FAE22E6@ibm.net> <369097C1.615@netfront.net> <3690c578.1416826@forums.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: ff5a1,e4cce62cc4a643dc X-Google-Attributes: gidff5a1,public From: pces <pces@netfront.net> Subject: Re: creating tables Date: 1999/01/06 Message-ID: <3692C120.3772F0FD@netfront.net> X-Deja-AN: 429242118 Content-Transfer-Encoding: 7bit References: <36905D71.848AE379@netfront.net> <36907CE3.6FAE22E6@ibm.net> <369097C1.615@netfront.net> <3690c578.1416826@forums.borland.com> Content-Type: text/plain; charset=us-ascii Organization: Another Netscape Collabra Server User Mime-Version: 1.0 Reply-To: pces@netfront.net Newsgroups: borland.public.vdbase.data.sql