Charlotte Foust
cfoust at infostatsystems.com
Wed Jan 29 18:29:01 CST 2003
You don't have to parse it if you use CurrentProject.Path instead. Charlotte Foust -----Original Message----- From: Arthur Fuller [mailto:artful at rogers.com] Sent: Wednesday, January 29, 2003 4:14 PM To: accessd at databaseadvisors.com Subject: Re: [AccessD] CurrentDB in ADP In an ADP's debug window: ? currentproject.FullName F:\Access\2020.adp Parse it as you do already and you're there. hth, Arthur ----- Original Message ----- From: "David Emerson" <davide at dalyn.co.nz> To: <accessd at databaseadvisors.com> Sent: Wednesday, January 29, 2003 6:47 PM Subject: [AccessD] CurrentDB in ADP > I have some 97 code which returns the folder the current database is > in - > > Dim dbs As DAO.Database, strLoop As Integer > > Set dbs = CurrentDb() > For strLoop = Len(dbs.Name) - 1 To 1 Step -1 > If Mid$(dbs.Name, strLoop, 1) = "\" Then > basGetCurrentFolder = Left$(dbs.Name, strLoop - 1) > Exit For > End If > Next > > I am upgrading it for an XP ADP. When it is run the Currentdb call returns > nothing. > > I have made sure that the DAO 3.6 Object library is checked in > references (as per help). What is wrong, or is there an easier way to > get the current > folder? I tried CurDir but this is not what I want. > > > Regards > > David Emerson > DALYN Software Ltd > 25b Cunliffe St, Johnsonville > Wellington, New Zealand > Ph/Fax (877) 456-1205 > > _______________________________________________ > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com _______________________________________________ AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com